Authored by ccbikai(👎🏻🍜)

Merge branch 'release/5.5.1' into gray

@@ -385,10 +385,10 @@ const order = (params) => { @@ -385,10 +385,10 @@ const order = (params) => {
385 * @param params 385 * @param params
386 */ 386 */
387 const getOrders = (params) => { 387 const getOrders = (params) => {
388 - let finalResult = []; 388 + let finalResult = Promise.resolve([]);
389 389
390 if (!params.uid) { 390 if (!params.uid) {
391 - return Promise.resolve({}); 391 + return Promise.resolve([]);
392 } 392 }
393 return _getOrderData(params).then(result => { 393 return _getOrderData(params).then(result => {
394 if (result.data && result.data.page_total && params.page <= result.data.page_total && result.data.order_list) { 394 if (result.data && result.data.page_total && params.page <= result.data.page_total && result.data.order_list) {
@@ -28,32 +28,32 @@ module.exports = () => { @@ -28,32 +28,32 @@ module.exports = () => {
28 28
29 if (/^\/help\/limitcodeIntro/.test(req.url)) { 29 if (/^\/help\/limitcodeIntro/.test(req.url)) {
30 // 什么是限购码 兼容PHP的url 30 // 什么是限购码 兼容PHP的url
31 - req.url = `/service/limitcodeIntro`; 31 + req.url = '/service/limitcodeIntro';
32 } 32 }
33 33
34 if (/^\/help\/limitcodeColSize/.test(req.url)) { 34 if (/^\/help\/limitcodeColSize/.test(req.url)) {
35 // 选择限购码颜色和尺寸 兼容PHP的url 35 // 选择限购码颜色和尺寸 兼容PHP的url
36 - req.url = `/service/limitcodeColSize`; 36 + req.url = '/service/limitcodeColSize';
37 } 37 }
38 38
39 if (/^\/help\/limitcodeHelp/.test(req.url)) { 39 if (/^\/help\/limitcodeHelp/.test(req.url)) {
40 // 如何获得限购码 兼容PHP的url 40 // 如何获得限购码 兼容PHP的url
41 - req.url = `/service/limitcodeHelp`; 41 + req.url = '/service/limitcodeHelp';
42 } 42 }
43 43
44 if (/^\/help\/shareorder\.html/.test(req.url)) { 44 if (/^\/help\/shareorder\.html/.test(req.url)) {
45 // 晒单 兼容PHP的url 45 // 晒单 兼容PHP的url
46 - req.url = `/service/shareorder`; 46 + req.url = '/service/shareorder';
47 } 47 }
48 48
49 if (/^\/index\/systemUpdate/.test(req.url)) { 49 if (/^\/index\/systemUpdate/.test(req.url)) {
50 // 升级公告 兼容PHP的url 50 // 升级公告 兼容PHP的url
51 - req.url = `/service/systemUpdate`; 51 + req.url = '/service/systemUpdate';
52 } 52 }
53 53
54 if (/^\/coupon\/couponSend/.test(req.url)) { 54 if (/^\/coupon\/couponSend/.test(req.url)) {
55 // 获取优惠券 兼容php的url 55 // 获取优惠券 兼容php的url
56 - req.url = `/activity/couponSend`; 56 + req.url = '/activity/couponSend';
57 } 57 }
58 58
59 next(); 59 next();
@@ -2,10 +2,10 @@ require('activity/promotion/promotion.page.css'); @@ -2,10 +2,10 @@ require('activity/promotion/promotion.page.css');
2 2
3 let $ = require('yoho-jquery'); 3 let $ = require('yoho-jquery');
4 let tip = require('plugin/tip'); 4 let tip = require('plugin/tip');
5 - 5 +let AsideSlider = require('./aslider');
6 let dialog = require('plugin/dialog'); 6 let dialog = require('plugin/dialog');
7 7
8 -; //eslint-disable-line 8 +let asideSlider = new AsideSlider(); //eslint-disable-line
9 9
10 let province, 10 let province,
11 school; 11 school;
@@ -130,7 +130,7 @@ function getOrders(option) { @@ -130,7 +130,7 @@ function getOrders(option) {
130 success: function(data) { 130 success: function(data) {
131 let num; 131 let num;
132 132
133 - if (data !== '') { 133 + if (data.length > 0) {
134 134
135 order.page = opt.page; 135 order.page = opt.page;
136 136
@@ -74,15 +74,15 @@ const getAppPath = () => { @@ -74,15 +74,15 @@ const getAppPath = () => {
74 74
75 if (canOpenApp()) { 75 if (canOpenApp()) {
76 setTimeout(function() { 76 setTimeout(function() {
77 - if (window._yas && window._yas.sendCustomInfo) {  
78 - window._yas.sendCustomInfo({  
79 - op: 'YB_H5_AWAKE_APP',  
80 - param: JSON.stringify({  
81 - PAGE_NAME: encodeURIComponent(document.title),  
82 - PAGE_URL: encodeURIComponent(location.href)  
83 - })  
84 - }, true);  
85 - } 77 + // if (window._yas && window._yas.sendCustomInfo) {
  78 + // window._yas.sendCustomInfo({
  79 + // op: 'YB_H5_AWAKE_APP',
  80 + // param: JSON.stringify({
  81 + // PAGE_NAME: encodeURIComponent(document.title),
  82 + // PAGE_URL: encodeURIComponent(location.href)
  83 + // })
  84 + // }, true);
  85 + // }
86 86
87 if (window._hmt && window._hmt.push) { 87 if (window._hmt && window._hmt.push) {
88 window._hmt.push(['_trackEvent', 'H5唤起APP', isiOS ? 'Apple' : 'Android', document.title, location.href]); 88 window._hmt.push(['_trackEvent', 'H5唤起APP', isiOS ? 'Apple' : 'Android', document.title, location.href]);
@@ -70,12 +70,15 @@ $('.res-c').on('click', 'a', function() { @@ -70,12 +70,15 @@ $('.res-c').on('click', 'a', function() {
70 } 70 }
71 71
72 if (window._yas && window._yas.sendCustomInfo) { 72 if (window._yas && window._yas.sendCustomInfo) {
73 - window._yas.sendCustomInfo({  
74 - I_INDEX: index,  
75 - F_URL: encodeURIComponent(url),  
76 - F_NAME: name,  
77 - F_INDEX: pIndex,  
78 - F_ID: id 73 + window._yas.sendCustomInfo && window._yas.sendCustomInfo({
  74 + op: 'YB_MY_BANNER_C',
  75 + param: JSON.stringify({
  76 + I_INDEX: index,
  77 + F_URL: encodeURIComponent(url),
  78 + F_NAME: name,
  79 + F_INDEX: pIndex,
  80 + F_ID: id
  81 + })
79 }, true); 82 }, true);
80 } 83 }
81 }); 84 });