Toggle navigation
Toggle navigation
This project
Loading...
Sign in
mobile
/
YH_RNComponent
·
Commits
Go to a project
GitLab
Go to group
Project
Activity
Files
Commits
Pipelines
0
Builds
0
Graphs
Milestones
Issues
0
Merge Requests
0
Members
Labels
Wiki
Forks
Network
Create a new issue
Download as
Email Patches
Plain Diff
Browse Files
Authored by
张丽霞
8 years ago
Commit
a8c3683582627223df03c32480f1d161a06aa88e
1 parent
833f3c10
店铺和红人店铺埋点,review by redding
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
47 additions
and
8 deletions
js/brandStore/containers/BrandStoreContainer.js
js/brandStore/reducers/brandStore/brandStoreActions.js
js/redPersonBrand/containers/RedPersonBrandContainer.js
js/redPersonBrand/reducers/redBrand/redBrandActions.js
js/brandStore/containers/BrandStoreContainer.js
View file @
a8c3683
...
...
@@ -89,8 +89,6 @@ class BrandStoreContainer extends Component {
this
.
props
.
actions
.
getShopResources
();
this
.
props
.
actions
.
getFavoriteState
();
// this.props.actions.setShowSimilarGuider(true);
ReactNative
.
NativeModules
.
YH_CommonHelper
.
logEvent
(
'YB_BRAND_SHOP_L'
,
{
SHOP_ID
:
this
.
props
.
brandStore
.
shopId
,
BRAND_ID
:
this
.
props
.
brandStore
.
resource
.
brandBrowse
.
brandId
});
}
componentWillUnmount
()
{
...
...
@@ -120,17 +118,19 @@ class BrandStoreContainer extends Component {
_onPressCollection
(
isCollected
)
{
let
param
=
{
SHOP_ID
:
this
.
props
.
brandStore
.
shopId
,
BRAND_ID
:
this
.
props
.
brandStore
.
resource
.
brandBrowse
.
brandId
,
COL_TYPE
:
1
,
}
let
param
=
{
SHOP_ID
:
this
.
props
.
brandStore
.
shopId
,
BRAND_ID
:
this
.
props
.
brandStore
.
resource
.
brandBrowse
.
brandId
,
COL_TYPE
:
1
,
}
if
(
isCollected
)
{
this
.
props
.
actions
.
addFavorite
();
param
=
{
SHOP_ID
:
this
.
props
.
brandStore
.
shopId
,
BRAND_ID
:
this
.
props
.
brandStore
.
resource
.
brandBrowse
.
brandId
,
COL_TYPE
:
1
,
TEMPLATE_TYPE
:
this
.
props
.
brandStore
.
info
.
shop_template_type
,
IS_RED
:
0
,
}
}
else
{
this
.
props
.
actions
.
cancelFavorite
();
...
...
@@ -138,9 +138,10 @@ class BrandStoreContainer extends Component {
SHOP_ID
:
this
.
props
.
brandStore
.
shopId
,
BRAND_ID
:
this
.
props
.
brandStore
.
resource
.
brandBrowse
.
brandId
,
COL_TYPE
:
2
,
TEMPLATE_TYPE
:
this
.
props
.
brandStore
.
info
.
shop_template_type
,
IS_RED
:
0
,
}
}
ReactNative
.
NativeModules
.
YH_CommonHelper
.
logEvent
(
'YB_BRAND_SHOP_COLLECT_C'
,
param
);
}
...
...
@@ -325,6 +326,8 @@ class BrandStoreContainer extends Component {
BRAND_ID
:
this
.
props
.
brandStore
.
resource
.
brandBrowse
.
brandId
,
TAB_ID
:
value
,
TAB_NAME
:
name
,
TEMPLATE_TYPE
:
this
.
props
.
brandStore
.
info
.
shop_template_type
,
IS_RED
:
0
,
}
ReactNative
.
NativeModules
.
YH_CommonHelper
.
logEvent
(
'YB_BRAND_SHOP_TAB_C'
,
param
);
this
.
props
.
actions
.
setSimilarIndex
(
-
1
);
...
...
js/brandStore/reducers/brandStore/brandStoreActions.js
View file @
a8c3683
...
...
@@ -225,6 +225,7 @@ export function getShopInfo() {
SHOP_ID
:
json
.
shops_id
?
json
.
shops_id
:
'0'
,
}
dispatch
(
shopDataExposure
(
'YB_SHOW_CLASSICAL_SHOP_INFO'
,
params
));
ReactNative
.
NativeModules
.
YH_CommonHelper
.
logEvent
(
'YB_BRAND_SHOP_L'
,
{
SHOP_ID
:
brandStore
.
shopId
,
TEMPLATE
:
json
.
shop_template_type
,
IS_RED
:
0
});
})
.
catch
(
error
=>
{
dispatch
(
shopInfoFailure
(
error
));
...
...
js/redPersonBrand/containers/RedPersonBrandContainer.js
View file @
a8c3683
...
...
@@ -93,11 +93,31 @@ class RedPersonBrandContainer extends Component {
_onPressCollection
(
isCollected
)
{
let
param
=
{
SHOP_ID
:
this
.
props
.
redBrand
.
shopId
,
COL_TYPE
:
1
,
}
if
(
!
isCollected
)
{
this
.
props
.
actions
.
addFavorite
();
param
=
{
SHOP_ID
:
this
.
props
.
redBrand
.
shopId
,
COL_TYPE
:
1
,
TEMPLATE_TYPE
:
this
.
props
.
redBrand
.
shopIntro
.
shop_template_type
,
IS_RED
:
1
,
}
}
else
{
this
.
props
.
actions
.
cancelFavorite
();
param
=
{
SHOP_ID
:
this
.
props
.
redBrand
.
shopId
,
COL_TYPE
:
2
,
TEMPLATE_TYPE
:
this
.
props
.
redBrand
.
shopIntro
.
shop_template_type
,
IS_RED
:
1
,
}
}
ReactNative
.
NativeModules
.
YH_CommonHelper
.
logEvent
(
'YB_BRAND_SHOP_COLLECT_C'
,
param
);
}
_onPressLaunchProfile
(
value
){
...
...
@@ -106,6 +126,20 @@ class RedPersonBrandContainer extends Component {
_onPressStoreFilter
(
value
)
{
this
.
props
.
actions
.
setFilter
(
value
);
let
name
=
'首页'
;
if
(
value
==
1
)
{
name
=
'新品'
;
}
else
if
(
value
==
2
)
{
name
=
'全部商品'
;
}
let
param
=
{
SHOP_ID
:
this
.
props
.
redBrand
.
shopId
,
TAB_ID
:
value
,
TAB_NAME
:
name
,
TEMPLATE_TYPE
:
this
.
props
.
redBrand
.
shopIntro
.
shop_template_type
,
IS_RED
:
1
,
}
ReactNative
.
NativeModules
.
YH_CommonHelper
.
logEvent
(
'YB_BRAND_SHOP_TAB_C'
,
param
);
}
_onPressLink
(
url
)
{
...
...
js/redPersonBrand/reducers/redBrand/redBrandActions.js
View file @
a8c3683
...
...
@@ -583,6 +583,7 @@ export function getIntro() {
return
new
RedBrandService
(
app
.
host
).
getIntro
(
shopId
)
.
then
(
json
=>
{
dispatch
(
getIntroSuccess
(
json
));
ReactNative
.
NativeModules
.
YH_CommonHelper
.
logEvent
(
'YB_BRAND_SHOP_L'
,
{
SHOP_ID
:
redBrand
.
shopId
,
TEMPLATE
:
json
.
shop_template_type
,
IS_RED
:
1
});
})
.
catch
(
error
=>
{
dispatch
(
getIntroFailure
(
error
));
...
...
Please
register
or
login
to post a comment