Authored by ccbikai(👎🏻🍜)

Merge branch 'feature/registerYas'

... ... @@ -12,3 +12,27 @@ exports.wechatShare = (req, res, next) => {
res.jsonp(result);
}).catch(next);
};
/**
* 活动页<http://feature.yoho.cn/1101/1101ITEMBOY/index.html?title=%E7%94%B7%E7%94%9F%E5%88%86%E4%BC%9A%E5%9C%BA&share_id=814&mkt_code=1011111#a_01>
* <xiaoxiao.hao@yoho.cn>
* 2016/07/13
*/
// 活动页保存相应cookie的值
exports.feature = (req, res) => {
let mktCode = req.query.mkt_code || false;
// 下载浮层,下载按钮会用到该参数
if (mktCode) {
res.cookie('mkt_code', mktCode, {
domain: '.yohobuy.com',
path: '/'
});
res.cookie('unionTypeYas', mktCode, {
path: '/'
});
}
res.json({mktCode: mktCode});
};
\ No newline at end of file
... ...
... ... @@ -116,4 +116,7 @@ router.get('/vip-day1028/crazy-luck', vipDay1028.beforeIn, vipDay1028.crazyLuck)
router.post('/vip-day1028/signin.json', vipDay1028.beforeIn, vipDay1028.signin);
router.post('/vip-day1028/isStudent', vipDay1028.beforeIn, vipDay1028.checkIsStudent);
// 获取活动页传来的参数
router.get('/wechat/1111', wechat.feature);
module.exports = router;
... ...
{
"name": "m-yohobuy-node",
"version": "5.1.8",
"version": "5.1.9",
"private": true,
"description": "A New Yohobuy Project With Express",
"repository": {
... ...
... ... @@ -127,6 +127,8 @@ var singleDay = {
$swiperTab.on('click', function() {
var index = $(this).index();
$('body').scrollTop(0);
$swiperTab.removeClass('active').eq(index).addClass('active');
if (self.$productTab.eq(index).find('li').length > 0) {
... ...
... ... @@ -14,6 +14,8 @@ var tip = require('../../plugin/tip');
var trim = $.trim;
var showErrTip = tip.show;
require('../../common');
api.bindEyesEvt({
status: 'open' // 默认眼睛打开
});
... ... @@ -49,6 +51,16 @@ $btnSure.on('touchstart', function() {
var res = data.data;
if (data.code === 200) {
// 统计代码:用于统计从哪个渠道注册成功的
if (window._yas && window._yas.sendCustomInfo) {
window._yas.sendCustomInfo({
op: 'YB_REGISTER_SUCCESS_L',
param: JSON.stringify({
C_ID: window._ChannelVary[window.cookie('_Channel')] || 1,
UNION_TYPE: window.queryString.union_type || window.cookie('unionTypeYas') || false
})
}, true);
}
showErrTip('注册成功');
location.href = res.href;
... ...
... ... @@ -199,7 +199,7 @@ function getPageGoods(info) {
url: info.url,
data: info.data,
success: function(data) {
if (data === ' ') {
if (data === '') {
nav.end = true;
}
... ... @@ -325,6 +325,7 @@ var theY;
*/
function reNav1Pos() {
var sTop = theY ? theY : 0;
if (sTop < imgH + main1oH + nav1H) {
if ($nav1.hasClass('hide')) {
$nav1.removeClass('hide');
... ... @@ -385,6 +386,7 @@ function scrollHandler() {
if (sTop + winH * 2 > scH) {
scrollCall = function() {
var translate = 'translate3d(0, ' + (-scH) + 'px, 0)';
$nav1.css({
transform: translate,
'-moz-transform': translate,
... ... @@ -681,7 +683,7 @@ function search(opt) {
break;
}
if (data === ' ') {
if (data === '') {
nav.end = true;
if (nav.reload) {
... ... @@ -929,6 +931,7 @@ $nav2.on('touchstart', 'li', function(e) {
$('.shop-foot-wrapper .buriedpoint').click(function() {
var subGroup = $(this).find('.sub-group');
if (subGroup.hasClass('hide')) {
subGroup.removeClass('hide');
} else {
... ...