Authored by ccbikai(👎🏻🍜)

Merge branch 'release/5.3' into gray

@@ -78,11 +78,11 @@ @@ -78,11 +78,11 @@
78 </section> 78 </section>
79 79
80 {{#if isJit}} 80 {{#if isJit}}
81 - {{> me/order/jit-more}} 81 + {{> home/order/jit-more}}
82 {{/if}} 82 {{/if}}
83 <section class="block goods-bottom"> 83 <section class="block goods-bottom">
84 {{#each goods}} 84 {{#each goods}}
85 - {{> me/order/good}} 85 + {{> home/order/good}}
86 {{/each}} 86 {{/each}}
87 <div class="goods-num">{{num}}件商品 合计<span>{{goodsPrice}}</span></div> 87 <div class="goods-num">{{num}}件商品 合计<span>{{goodsPrice}}</span></div>
88 </section> 88 </section>
@@ -168,7 +168,7 @@ @@ -168,7 +168,7 @@
168 实付金额 168 实付金额
169 <span>¥{{round price 2}}</span> 169 <span>¥{{round price 2}}</span>
170 </div> 170 </div>
171 - 171 +
172 {{#if returnYohoCoin}} 172 {{#if returnYohoCoin}}
173 <div class="yoho-coin"> 173 <div class="yoho-coin">
174 共返有货币: {{yohoCoinNum}} 174 共返有货币: {{yohoCoinNum}}
@@ -15,7 +15,7 @@ exports.get = (req, res, next) => { @@ -15,7 +15,7 @@ exports.get = (req, res, next) => {
15 15
16 req.session.captcha = codeStr; 16 req.session.captcha = codeStr;
17 17
18 - data.src = result.data.verifiedGraphicCode; 18 + data.src = result.data.verifiedGraphicCode.replace(/^http:/, '');
19 19
20 return res.json(data); 20 return res.json(data);
21 } 21 }
@@ -16,21 +16,21 @@ module.exports = { @@ -16,21 +16,21 @@ module.exports = {
16 siteUrl: '//m.yohobuy.com', 16 siteUrl: '//m.yohobuy.com',
17 assetUrl: '//127.0.0.1:5001', 17 assetUrl: '//127.0.0.1:5001',
18 domains: { 18 domains: {
19 - api: 'http://api-test3.yohops.com:9999/',  
20 - service: 'http://service-test3.yohops.com:9999/',  
21 - liveApi: 'http://testapi.live.yohops.com:9999/',  
22 - singleApi: 'http://api-test3.yohops.com:9999/',  
23 - imSocket: 'ws://im.yohobuy.com:10240',  
24 - imCs: 'http://im.yohobuy.com/api',  
25 - imServer: 'http://im.yohobuy.com/server' 19 + // api: 'http://api-test3.yohops.com:9999/',
  20 + // service: 'http://service-test3.yohops.com:9999/',
  21 + // liveApi: 'http://testapi.live.yohops.com:9999/',
  22 + // singleApi: 'http://api-test3.yohops.com:9999/',
  23 + // imSocket: 'ws://im.yohobuy.com:10240',
  24 + // imCs: 'http://im.yohobuy.com/api',
  25 + // imServer: 'http://im.yohobuy.com/server'
26 26
27 - // api: 'http://api.yoho.cn/',  
28 - // service: 'http://service.yoho.cn/',  
29 - // liveApi: 'http://api.live.yoho.cn/',  
30 - // singleApi: 'http://single.yoho.cn/',  
31 - // imSocket: 'ws://imsocket.yohobuy.com:10000',  
32 - // imCs: 'https://imhttp.yohobuy.com/api',  
33 - // imServer: 'https://imhttp.yohobuy.com/server' 27 + api: 'http://api.yoho.cn/',
  28 + service: 'http://service.yoho.cn/',
  29 + liveApi: 'http://api.live.yoho.cn/',
  30 + singleApi: 'http://single.yoho.cn/',
  31 + imSocket: 'ws://imsocket.yohobuy.com:10000',
  32 + imCs: 'https://imhttp.yohobuy.com/api',
  33 + imServer: 'https://imhttp.yohobuy.com/server'
34 }, 34 },
35 subDomains: { 35 subDomains: {
36 host: '.m.yohobuy.com', 36 host: '.m.yohobuy.com',
@@ -58,7 +58,14 @@ module.exports = () => { @@ -58,7 +58,14 @@ module.exports = () => {
58 58
59 // 已经废弃,只是对老页面做兼容 --start 59 // 已经废弃,只是对老页面做兼容 --start
60 case 'sale': // sale 跳转到 m.yohobuy.com/product/sale 60 case 'sale': // sale 跳转到 m.yohobuy.com/product/sale
61 - res.redirect(301, helpers.urlFormat('/product/sale', req.query, 'default')); 61 + if (_.keys(req.query).length) {
  62 + req.query.title = '专区活动';
  63 +
  64 + delete req.query['openby:yohobuy'];
  65 + res.redirect(301, helpers.urlFormat('/', req.query, 'list'));
  66 + } else {
  67 + res.redirect(301, helpers.urlFormat('/product/sale', req.query, 'default'));
  68 + }
62 return; 69 return;
63 case 'cart': // 购物车 跳转到 m.yohobuy.com/cart/index/index 70 case 'cart': // 购物车 跳转到 m.yohobuy.com/cart/index/index
64 res.redirect(301, helpers.urlFormat('/cart/index/index', req.query, 'default')); 71 res.redirect(301, helpers.urlFormat('/cart/index/index', req.query, 'default'));
@@ -5,7 +5,7 @@ @@ -5,7 +5,7 @@
5 </header> 5 </header>
6 <section class="order-goods"> 6 <section class="order-goods">
7 {{# goods}} 7 {{# goods}}
8 - {{> me/order/good}} 8 + {{> home/order/good}}
9 {{/ goods}} 9 {{/ goods}}
10 </section> 10 </section>
11 <footer class="footer"> 11 <footer class="footer">
@@ -63,6 +63,6 @@ @@ -63,6 +63,6 @@
63 </a> 63 </a>
64 </div> 64 </div>
65 {{/if}} 65 {{/if}}
66 - 66 +
67 {{/if}} 67 {{/if}}
68 -</div>  
  68 +</div>
@@ -6,6 +6,6 @@ @@ -6,6 +6,6 @@
6 </div> 6 </div>
7 {{^}} 7 {{^}}
8 {{#each orders}} 8 {{#each orders}}
9 - {{> me/order/order}} 9 + {{> home/order/order}}
10 {{/each}} 10 {{/each}}
11 -{{/if}}  
  11 +{{/if}}
@@ -44,9 +44,6 @@ plusstar = { @@ -44,9 +44,6 @@ plusstar = {
44 44
45 // 事情委托机制 45 // 事情委托机制
46 $tabUlDom.bind('click', function(event) { 46 $tabUlDom.bind('click', function(event) {
47 - if (!window._yas || !window._yas.sendCustomInfo) {  
48 - return;  
49 - }  
50 47
51 $liDom = $(event.target).closest('li'); 48 $liDom = $(event.target).closest('li');
52 49
@@ -59,6 +56,9 @@ plusstar = { @@ -59,6 +56,9 @@ plusstar = {
59 that.ParentLiDom = $liDom;// 保留当前tab先中的对象 56 that.ParentLiDom = $liDom;// 保留当前tab先中的对象
60 that.tabNav($liDom.data('code')); 57 that.tabNav($liDom.data('code'));
61 58
  59 + if (!window._yas || !window._yas.sendCustomInfo) {
  60 + return;
  61 + }
62 // 点击潮流优选上方的TAB按钮时 62 // 点击潮流优选上方的TAB按钮时
63 window._yas.sendCustomInfo({ 63 window._yas.sendCustomInfo({
64 op: 'YB_FASHION_TAB_C', 64 op: 'YB_FASHION_TAB_C',
@@ -96,10 +96,10 @@ C_ID = window._ChannelVary[window.cookie('_Channel')]; @@ -96,10 +96,10 @@ C_ID = window._ChannelVary[window.cookie('_Channel')];
96 }, 96 },
97 dataType: 'json', 97 dataType: 'json',
98 success: function(data) { 98 success: function(data) {
99 - $('.con').text(data.intro);  
100 if (data.collected) { 99 if (data.collected) {
101 $('.brand-header .btn-col').addClass('coled'); 100 $('.brand-header .btn-col').addClass('coled');
102 } 101 }
  102 + $('.con').html(data.intro);
103 }, 103 },
104 error: function() { 104 error: function() {
105 tip.show('网络断开连接了~'); 105 tip.show('网络断开连接了~');
@@ -116,7 +116,7 @@ C_ID = window._ChannelVary[window.cookie('_Channel')]; @@ -116,7 +116,7 @@ C_ID = window._ChannelVary[window.cookie('_Channel')];
116 if (data.is_favorite === 'Y') { 116 if (data.is_favorite === 'Y') {
117 $('.brand-header .btn-col').addClass('coled'); 117 $('.brand-header .btn-col').addClass('coled');
118 } 118 }
119 - $('.con').text(data.shop_intro); 119 + $('.con').html(data.shop_intro);
120 }, 120 },
121 error: function() { 121 error: function() {
122 tip.show('网络断开连接了~'); 122 tip.show('网络断开连接了~');
@@ -410,7 +410,7 @@ function search(opt) { @@ -410,7 +410,7 @@ function search(opt) {
410 } 410 }
411 411
412 yasparm = { 412 yasparm = {
413 - C_ID: C_ID, 413 + C_ID: C_ID,
414 BRAND_ID: setting.shop_id, 414 BRAND_ID: setting.shop_id,
415 PAGE_NUM: setting.page, 415 PAGE_NUM: setting.page,
416 FILTER_VALUE: opt ? JSON.stringify(filext).replace(/\{|\}|\"/g, '') : '', 416 FILTER_VALUE: opt ? JSON.stringify(filext).replace(/\{|\}|\"/g, '') : '',
@@ -440,7 +440,7 @@ function search(opt) { @@ -440,7 +440,7 @@ function search(opt) {
440 }, 200); 440 }, 200);
441 } 441 }
442 } else { 442 } else {
443 - 443 +
444 444
445 if (nav.reload) { 445 if (nav.reload) {
446 446
@@ -452,8 +452,8 @@ function search(opt) { @@ -452,8 +452,8 @@ function search(opt) {
452 } else if ($(goodInfo).hasClass('total')) { 452 } else if ($(goodInfo).hasClass('total')) {
453 total = $(goodInfo).data('id'); 453 total = $(goodInfo).data('id');
454 } 454 }
455 - });  
456 - 455 + });
  456 +
457 yasparm = Object.assign(yasparm, { 457 yasparm = Object.assign(yasparm, {
458 PRD_LIST: JSON.stringify(goodIds).replace(/\[|\]/g, ''), 458 PRD_LIST: JSON.stringify(goodIds).replace(/\[|\]/g, ''),
459 RES_QTY: total 459 RES_QTY: total
@@ -906,10 +906,10 @@ $('#goods-container').on('click', '.good-info', function() { @@ -906,10 +906,10 @@ $('#goods-container').on('click', '.good-info', function() {
906 PRD_NUM: PRD_NUM, 906 PRD_NUM: PRD_NUM,
907 PAGE_NUM: Math.ceil(PRD_NUM / 60), 907 PAGE_NUM: Math.ceil(PRD_NUM / 60),
908 FILTER_VALUE: FILTER_VALUE, 908 FILTER_VALUE: FILTER_VALUE,
909 - SORT_TYPE: argument ? argument.type : '' 909 + SORT_TYPE: argument ? argument.type : ''
910 }) 910 })
911 }, true); 911 }, true);
912 } 912 }
913 913
914 // return false; 914 // return false;
915 -});  
  915 +});
@@ -381,7 +381,7 @@ var chat = { @@ -381,7 +381,7 @@ var chat = {
381 break; 381 break;
382 case allTypes.ROBOT_SEND: 382 case allTypes.ROBOT_SEND:
383 viewData.from = 'rebot'; 383 viewData.from = 'rebot';
384 - viewData.avatar = socketConf.defaultUserHead; 384 + viewData.avatar = socketConf.rebotUserHead;
385 break; 385 break;
386 386
387 default: 387 default:
1 -/* global gDomains */ 1 +/* global gDomains, gAssetURI */
2 /** 2 /**
3 * socket config 3 * socket config
4 * 4 *
@@ -9,6 +9,7 @@ @@ -9,6 +9,7 @@
9 var config = { 9 var config = {
10 servers: [gDomains.imSocket], 10 servers: [gDomains.imSocket],
11 defaultUserHead: '//img10.static.yhbimg.com/headimg/2013/11/28/09/01cae078abe5fe320c88cdf4c220212688.gif', 11 defaultUserHead: '//img10.static.yhbimg.com/headimg/2013/11/28/09/01cae078abe5fe320c88cdf4c220212688.gif',
  12 + rebotUserHead: `${gAssetURI}/img/service/chat/im-robot.png`,
12 recType: { 13 recType: {
13 ENTER: 1, // 用户进入 14 ENTER: 1, // 用户进入
14 LINK_SUCCESS: 2, // 连线人工客服回应 15 LINK_SUCCESS: 2, // 连线人工客服回应