Commit 1146a7ee0d3f8de2258a08394bd6231d181f6883
Merge branch 'dev' of http://git.vipzhuang.cn/wxd/MShopWeApp into test
Showing
2 changed files
with
29 additions
and
20 deletions
pages/goods/search/search.js
@@ -44,23 +44,29 @@ Page({ | @@ -44,23 +44,29 @@ Page({ | ||
44 | 44 | ||
45 | onLoad: function (t) { | 45 | onLoad: function (t) { |
46 | this.data.rq_data = t; | 46 | this.data.rq_data = t; |
47 | - | 47 | + |
48 | if (t.o) { | 48 | if (t.o) { |
49 | this.data.rq_data.o = JSON.parse(t.o); | 49 | this.data.rq_data.o = JSON.parse(t.o); |
50 | }; | 50 | }; |
51 | - var req = t.o; | ||
52 | - if(req.cat_id){ | ||
53 | - var baseUrl= "/api/weshop/goods/page?isnewwhere=1&cat_id="+req.cat_id | ||
54 | - this.setData({ baseUrl: baseUrl }); | ||
55 | - } | ||
56 | - if(req.nation_id){ | ||
57 | - var baseUrl= "/api/weshop/goods/page?isnewwhere=1&nation_id="+req.nation_id | ||
58 | - this.setData({ baseUrl: baseUrl }); | ||
59 | - } | ||
60 | - if(req.brand_id){ | ||
61 | - var baseUrl= "/api/weshop/goods/page?isnewwhere=1&brand_id="+req.brand_id | 51 | + if(t.o) { |
52 | + var req = t.o; | ||
53 | + if(req.cat_id){ | ||
54 | + var baseUrl= "/api/weshop/goods/page?isnewwhere=1&cat_id="+req.cat_id | ||
55 | + this.setData({ baseUrl: baseUrl }); | ||
56 | + } | ||
57 | + if(req.nation_id){ | ||
58 | + var baseUrl= "/api/weshop/goods/page?isnewwhere=1&nation_id="+req.nation_id | ||
59 | + this.setData({ baseUrl: baseUrl }); | ||
60 | + } | ||
61 | + if(req.brand_id){ | ||
62 | + var baseUrl= "/api/weshop/goods/page?isnewwhere=1&brand_id="+req.brand_id | ||
63 | + this.setData({ baseUrl: baseUrl }); | ||
64 | + } | ||
65 | + }else{ | ||
66 | + var baseUrl= "/api/weshop/goods/page?isnewwhere=1" | ||
62 | this.setData({ baseUrl: baseUrl }); | 67 | this.setData({ baseUrl: baseUrl }); |
63 | } | 68 | } |
69 | + | ||
64 | 70 | ||
65 | 71 | ||
66 | //接受有没有导购的参数 | 72 | //接受有没有导购的参数 |
pages/user/plus/plus.js
@@ -93,14 +93,7 @@ Page({ | @@ -93,14 +93,7 @@ Page({ | ||
93 | }) | 93 | }) |
94 | } | 94 | } |
95 | 95 | ||
96 | - //--先判断会员状态-- | ||
97 | - var user_info = getApp().globalData.userInfo; | ||
98 | - if (user_info == null || user_info.mobile == undefined || user_info.mobile == "" || user_info.mobile == null) { | ||
99 | - wx.navigateTo({ | ||
100 | - url: '/packageE/pages/togoin/togoin?first_leader=' + fir_leader, | ||
101 | - }) | ||
102 | - return false; | ||
103 | - } | 96 | + |
104 | //-----------商家配置信息----- 等级卡规则,是否又开邀请码,营业员------------ | 97 | //-----------商家配置信息----- 等级卡规则,是否又开邀请码,营业员------------ |
105 | getApp().request.get("/api/weshop/storeconfig/get/" + store_id, { | 98 | getApp().request.get("/api/weshop/storeconfig/get/" + store_id, { |
106 | success: function (res) { | 99 | success: function (res) { |
@@ -116,6 +109,16 @@ Page({ | @@ -116,6 +109,16 @@ Page({ | ||
116 | }); | 109 | }); |
117 | } | 110 | } |
118 | }); | 111 | }); |
112 | + | ||
113 | + //--先判断会员状态-- | ||
114 | + var user_info = getApp().globalData.userInfo; | ||
115 | + if (user_info == null || user_info.mobile == undefined || user_info.mobile == "" || user_info.mobile == null) { | ||
116 | + wx.navigateTo({ | ||
117 | + url: '/packageE/pages/togoin/togoin?first_leader=' + fir_leader, | ||
118 | + }) | ||
119 | + return false; | ||
120 | + } | ||
121 | + | ||
119 | }, | 122 | }, |
120 | 123 | ||
121 | /** | 124 | /** |