Authored by lijing

release/5.1合并master分支

@@ -17,7 +17,7 @@ const shopIndex = (req, res) => { @@ -17,7 +17,7 @@ const shopIndex = (req, res) => {
17 }) 17 })
18 }; 18 };
19 } else { 19 } else {
20 - uid = crypto.encryption('', req.query.uid + ''), 20 + uid = crypto.encryption('', req.query.uid + ''),
21 parameter = { 21 parameter = {
22 appVersion: true, 22 appVersion: true,
23 uid: uid 23 uid: uid
@@ -50,7 +50,6 @@ const banner = () => { @@ -50,7 +50,6 @@ const banner = () => {
50 cache: true, 50 cache: true,
51 code: 200 51 code: 200
52 }).then((result) => { 52 }).then((result) => {
53 -  
54 if (result && result.data) { 53 if (result && result.data) {
55 return result.data[0]; 54 return result.data[0];
56 } 55 }
@@ -81,25 +81,25 @@ function shopListData(tabName, stoping) { @@ -81,25 +81,25 @@ function shopListData(tabName, stoping) {
81 success: function(list) { 81 success: function(list) {
82 var url; 82 var url;
83 83
84 - if (list.code === 200) {  
85 - if ($this.hasClass('already-collect')) {  
86 - $this.removeClass('already-collect');  
87 - tip.show('店铺取消收藏成功');  
88 - } else {  
89 - $this.addClass('already-collect');  
90 - tip.show('店铺收藏成功'); 84 + if (list.code === 200) {
  85 + if ($this.hasClass('already-collect')) {
  86 + $this.removeClass('already-collect');
  87 + tip.show('店铺取消收藏成功');
  88 + } else {
  89 + $this.addClass('already-collect');
  90 + tip.show('店铺收藏成功');
  91 + }
91 } 92 }
92 - }  
93 93
94 - if (list.code === 400) { 94 + if (list.code === 400) {
95 95
96 - url = list.data;  
97 - if ($('#jump-login').length <= 0) {  
98 - $('body').append('<a href=\'' + url + '\'><span id="jump-login"><span></a>'); 96 + url = list.data;
  97 + if ($('#jump-login').length <= 0) {
  98 + $('body').append('<a href=\'' + url + '\'><span id="jump-login"><span></a>');
  99 + }
  100 + $('#jump-login').click();
99 } 101 }
100 - $('#jump-login').click();  
101 - }  
102 - searching = false; 102 + searching = false;
103 }, 103 },
104 error: function() { 104 error: function() {
105 tip.show('网络断开连接了~'); 105 tip.show('网络断开连接了~');