Merge branch 'hotfix/point' of git.yoho.cn:fe/YOHOBUYWAP into hotfix/point
Showing
6 changed files
with
24 additions
and
4 deletions
No preview for this file type
@@ -297,7 +297,7 @@ function reMarginFooter(fixedElement) { | @@ -297,7 +297,7 @@ function reMarginFooter(fixedElement) { | ||
297 | function givePoint(parameter) { | 297 | function givePoint(parameter) { |
298 | var CID = 1; | 298 | var CID = 1; |
299 | 299 | ||
300 | - if (!window._yas) { | 300 | + if (!window._yas || !window._yas.sendCustomInfo) { |
301 | return false; | 301 | return false; |
302 | } | 302 | } |
303 | 303 | ||
@@ -8027,7 +8027,7 @@ $('#likeBtn').on('touchstart', function() { | @@ -8027,7 +8027,7 @@ $('#likeBtn').on('touchstart', function() { | ||
8027 | }); | 8027 | }); |
8028 | 8028 | ||
8029 | // 统计代码:用于统计用户加入或取消商品收藏的动作 | 8029 | // 统计代码:用于统计用户加入或取消商品收藏的动作 |
8030 | - if (window._yas) { | 8030 | + if (window._yas && window._yas.sendCustomInfo) { |
8031 | window._yas.sendCustomInfo({ | 8031 | window._yas.sendCustomInfo({ |
8032 | pd: productId, | 8032 | pd: productId, |
8033 | fa: favorite | 8033 | fa: favorite |
@@ -8052,7 +8052,7 @@ $('#addtoCart').on('touchstart', function() { | @@ -8052,7 +8052,7 @@ $('#addtoCart').on('touchstart', function() { | ||
8052 | chosePanel.show(); | 8052 | chosePanel.show(); |
8053 | 8053 | ||
8054 | //统计代码:用于统计用户加入购物车的动作 | 8054 | //统计代码:用于统计用户加入购物车的动作 |
8055 | - if (window._yas) { | 8055 | + if (window._yas && window._yas.sendCustomInfo) { |
8056 | window._yas.sendCustomInfo({ | 8056 | window._yas.sendCustomInfo({ |
8057 | pd: productId, | 8057 | pd: productId, |
8058 | by: 1 | 8058 | by: 1 |
@@ -12366,7 +12366,8 @@ var $ = require("jquery"), | @@ -12366,7 +12366,8 @@ var $ = require("jquery"), | ||
12366 | noticeScroll = require("js/plugin/notice-scroll"); | 12366 | noticeScroll = require("js/plugin/notice-scroll"); |
12367 | 12367 | ||
12368 | var $userAvatar = $('.user-avatar'), | 12368 | var $userAvatar = $('.user-avatar'), |
12369 | - $listItem = $('.list-item'); | 12369 | + $listItem = $('.list-item'), |
12370 | + $studentVe = $('.students-entry'); | ||
12370 | var myImage = new Image(), | 12371 | var myImage = new Image(), |
12371 | avatar; | 12372 | avatar; |
12372 | 12373 | ||
@@ -12389,6 +12390,25 @@ $('.yoho-page').on('touchstart', '.list-item, .type-item, .order-title', functio | @@ -12389,6 +12390,25 @@ $('.yoho-page').on('touchstart', '.list-item, .type-item, .order-title', functio | ||
12389 | $(this).removeClass('highlight'); | 12390 | $(this).removeClass('highlight'); |
12390 | }); | 12391 | }); |
12391 | 12392 | ||
12393 | +var getChannel = function() { | ||
12394 | + var name = window.cookie('_Channel'); | ||
12395 | + | ||
12396 | + return { | ||
12397 | + boys: 1, | ||
12398 | + girls: 2, | ||
12399 | + kids: 3, | ||
12400 | + lifestyle: 4 | ||
12401 | + }[name] || 1; | ||
12402 | +}; | ||
12403 | + | ||
12404 | +$studentVe.on('click', function(){ | ||
12405 | + if (window._yas && window._yas.sendCustomInfo) { | ||
12406 | + window._yas.sendCustomInfo({ | ||
12407 | + C_ID: getChannel(), | ||
12408 | + SRC_ID: 2 | ||
12409 | + }, true); | ||
12410 | + } | ||
12411 | +}); | ||
12392 | }); | 12412 | }); |
12393 | define("js/product/recommend-for-you-user-center", ["swiper","jquery","lazyload","index"], function(require, exports, module){ | 12413 | define("js/product/recommend-for-you-user-center", ["swiper","jquery","lazyload","index"], function(require, exports, module){ |
12394 | /** | 12414 | /** |
This diff could not be displayed because it is too large.
This diff could not be displayed because it is too large.
No preview for this file type
No preview for this file type
-
Please register or login to post a comment