Authored by 郝肖肖

埋点处理

... ... @@ -58,16 +58,16 @@ plusstar = {
if (window._yas && window._yas.sendCustomInfo) {
window._yas.sendCustomInfo({
op: 'YB_FASHION_TAB_C',
param: JSON.stringify($.extend(speckParamApp, {
param: JSON.stringify($.extend({
TAB_ID: $liDom.index() + 1
}))
}, speckParamApp))
}, true);
window._yas.sendCustomInfo({
op: 'YB_FASHION_HOME_L',
param: JSON.stringify($.extend(speckParamApp, {
param: JSON.stringify($.extend({
TAB_ID: that.ParentLiDom.index() + 1
}))
}, speckParamApp))
}, true);
}
});
... ... @@ -104,28 +104,28 @@ plusstar = {
// 商品单击埋点
$dom = $(event.target).closest('.good-info');
index = $dom.index() + 1;
window.givePoint($.extend(speckParamApp, {
window.givePoint($.extend({
REC_POSE: RECPOSE,
PRD_ID: $dom.data('good-id'),
ORDER_CODE: '',
PRD_NUM: index % that.common.pagesize === 0 ? that.common.pagesize : index % that.common.pagesize,
ACTION_ID: 1,
page_num: Math.ceil(index / that.common.pagesize)
}));
}, speckParamApp));
} else if ($(event.target).closest('.banner-top').length > 0) {
// 头部banner楼层埋点
$dom = $(event.target).closest('li');
index = $dom.index() + 1;
window._yas.sendCustomInfo({
op: 'YB_FASHION_FLR_C',
param: JSON.stringify($.extend(speckParamApp, {
param: JSON.stringify($.extend({
TAB_ID: that.ParentLiDom.index() + 1,
F_ID: $dom.closest('ul').data('id'),
F_NAME: '焦点图',
F_URL: $dom.find('a').attr('href'),
F_INDEX: 1,
I_INDEX: index % 2 + 1// banner,li是双倍的
}))
}, speckParamApp))
}, true);
} else if ($(event.target).closest('.speck-title-image a').length > 0) {
// 各楼层埋点
... ... @@ -134,14 +134,14 @@ plusstar = {
window._yas.sendCustomInfo({
op: 'YB_FASHION_FLR_C',
param: JSON.stringify($.extend(speckParamApp, {
param: JSON.stringify($.extend({
TAB_ID: that.ParentLiDom.index() + 1,
F_ID: $dom.data('fid'),
F_NAME: $dom.data('name'),
F_URL: $domA.attr('href'),
F_INDEX: $dom.index() + 1,
I_INDEX: $domA.hasClass('more') ? 0 : ($domA.index() + 1)
}))
}, speckParamApp))
}, true);
}
});
... ... @@ -149,9 +149,9 @@ plusstar = {
// 潮流优选首页加载时
window._yas.sendCustomInfo({
op: 'YB_FASHION_HOME_L',
param: JSON.stringify($.extend(speckParamApp, {
param: JSON.stringify($.extend({
TAB_ID: that.ParentLiDom.index() + 1
}))
}, speckParamApp))
}, true);
},
tabNav: function(code) {
... ... @@ -248,14 +248,14 @@ plusstar = {
skn.push($(this).data('good-id'));
});
window.givePoint($.extend(speckParamApp, {
window.givePoint($.extend({
REC_POSE: RECPOSE,
PRD_ID: skn.join(','),
ORDER_CODE: '',
PRD_NUM: that.common.pagesize,
ACTION_ID: 0,
page_num: that.common.page++
}));
}, speckParamApp));
$('.plusstar-resources .goods').append(data);
... ...