Commit 0408cfdc76e3a185770e0d2459d4d53b3f7a6761

Authored by 后端研发-田富滉
2 parents 6341715b f7bc46ea

Merge branch 'qa' into 'master'

Qa

See merge request !5
... ... @@ -13,7 +13,7 @@ App({
13 13 config2: null,
14 14 code: null,
15 15 heigth:0,
16   - user_id: 5682068,// 4379287,// null,// 5682068,
  16 + user_id: null,// 4379287,// null,// 5682068,
17 17 buy_now:null,
18 18 picklist:null, //门店列表
19 19 wuliuprice: null, //物流价格表
... ...
images/add2.png 0 → 100644

22.9 KB

images/quanyi2.png 0 → 100644

17.2 KB

pages/goods/categoryList/categoryList.js
... ... @@ -67,7 +67,7 @@ Page({
67 67 if (e.categoryset.indexOf("," + 1 + ",") != -1) { that.setData({ is_show_pl: 1 }); }
68 68 if (e.categoryset.indexOf("," + 3 + ",") != -1) { that.setData({ is_show_pp: 1 }); }
69 69 if (e.categoryset.indexOf("," + 2 + ",") != -1) { that.setData({ is_show_gb: 1 }); }
70   - that.setData({ store_config: e });
  70 + that.setData({ store_config: e,is_do:1 });
71 71  
72 72 if (that.data.is_show_pl) that.setData({ currentTab: 0 });
73 73 else if (that.data.is_show_gb){ that.setData({ currentTab: 1 });that.get_nation(); }
... ... @@ -113,7 +113,7 @@ Page({
113 113 continue;
114 114 }
115 115 }
116   - t.setData({ catelist: arr});
  116 + t.setData({ catelist: arr});
117 117 }
118 118 });
119 119 },
... ...
pages/goods/categoryList/categoryList.wxml
... ... @@ -90,7 +90,7 @@
90 90 </view>
91 91 </block>
92 92  
93   -<block wx:else>
  93 +<block wx:elif="{{is_do}}">
94 94 <view class="no-data" >
95 95 <image class="cart-image" src="{{iurl}}/miniapp/images/cart-null.png"></image>
96 96 <view class="no-data-title">商家暂未设置分类</view>
... ...
pages/goods/goodsInfo/goodsInfo.js
... ... @@ -1349,6 +1349,15 @@ Page({
1349 1349 return false;
1350 1350 }
1351 1351  
  1352 + /*-- 还没有开始预热的也不显示 --*/
  1353 + if (t.data.data.show_time >now) {
  1354 + ee.setData({
  1355 + prom_type: 0,isshow:1,
  1356 + });
  1357 + ee.get_sku(os.stoid, ee.data.data.sku, gid);
  1358 + return false;
  1359 + }
  1360 +
1352 1361 var t_gd = ee.data.data;
1353 1362 var prom_end_time = ut.formatTime(t.data.data.end_time, "yyyy-MM-dd hh:mm:ss");
1354 1363 var prom_start_time = ut.formatTime(t.data.data.start_time, "yyyy-MM-dd hh:mm:ss");
... ... @@ -1435,6 +1444,15 @@ Page({
1435 1444 return false;
1436 1445 }
1437 1446  
  1447 + /*-- 还没有开始预热的也不显示 --*/
  1448 + if (t.data.data.show_time > now) {
  1449 + ee.setData({
  1450 + prom_type: 0,isshow:1,
  1451 + });
  1452 + ee.get_sku(os.stoid, ee.data.data.sku, gid);
  1453 + return false;
  1454 + }
  1455 +
1438 1456 //-------查看自己是不是有买过该团的商品,并还为支付,或者在进行中-------
1439 1457 getApp().request.get("/api/weshop/order/page", {
1440 1458 data: {
... ... @@ -2345,33 +2363,35 @@ Page({
2345 2363  
2346 2364 //把画板内容绘制成图片,并回调 画板图片路径
2347 2365 context.draw(false, function () {
2348   - console.log('draw callback')
2349   - wx.canvasToTempFilePath({
2350   - x: 0, y: 0,
2351   - width: 750,
2352   - height: 1217,
2353   - destWidth: 1.2 * 750 * 750 / that.data.screenWidth,
2354   - destHeight: 1.2 * 1217 * 750 / that.data.screenWidth,
2355   - canvasId: 'share',
2356   - success: function (res) {
2357   - that.setData({
2358   - shareImgPath: res.tempFilePath, canvasHidden: true
2359   - })
2360   - if (!res.tempFilePath) {
2361   - wx.showModal({
2362   - title: '提示',
2363   - content: '图片绘制中,请稍后重试',
2364   - showCancel: false
2365   - })
2366   - return false;
2367   - }
2368   - wx.previewImage({
2369   - //将图片预览出来
2370   - urls: [that.data.shareImgPath]
2371   - });
2372   - wx.hideLoading();
2373   - }
2374   - })
  2366 + setTimeout(function () {
  2367 + wx.canvasToTempFilePath({
  2368 + x: 0, y: 0,
  2369 + width: 750,
  2370 + height: 1217,
  2371 + destWidth: 1.2 * 750 * 750 / that.data.screenWidth,
  2372 + destHeight: 1.2 * 1217 * 750 / that.data.screenWidth,
  2373 + canvasId: 'share',
  2374 + success: function (res) {
  2375 + that.setData({
  2376 + shareImgPath: res.tempFilePath, canvasHidden: true
  2377 + })
  2378 + if (!res.tempFilePath) {
  2379 + wx.showModal({
  2380 + title: '提示',
  2381 + content: '图片绘制中,请稍后重试',
  2382 + showCancel: false
  2383 + })
  2384 + return false;
  2385 + }
  2386 + wx.previewImage({
  2387 + //将图片预览出来
  2388 + urls: [that.data.shareImgPath]
  2389 + });
  2390 + wx.hideLoading();
  2391 + }
  2392 + })
  2393 + },200)
  2394 +
2375 2395 });
2376 2396 });
2377 2397 }
... ...
pages/goods/goodsInfo/goodsInfo.wxml
... ... @@ -139,7 +139,7 @@
139 139 <!----显示价格,阶梯团---->
140 140 <block wx:if="{{prom_act.kttype==3}}">
141 141 <view class="jie_price flex">
142   - <view style='margin-right:75rpx' wx:for="{{prom_act.ct_rylist}}">
  142 + <view style='margin-right:26rpx' wx:for="{{prom_act.ct_rylist}}">
143 143 <view class="fs35 word-color">
144 144 <text class="fs24">¥</text>{{item.price}}</view>
145 145 <view class="fs24 t-c xc-person-number ">满{{item.rynum}}人</view>
... ... @@ -172,11 +172,7 @@
172 172 <!--//还差几人,剩余时间-->
173 173 <view class="rel">
174 174 <view class='ghaicha ellipsis-2 abs'>
175   - <text class='gred' wx:if="{{prom_act.max_ct_num >0}}">
176   - <text class="flex" wx:if="{{prom_act.max_ct_num - item.open_num>0}}">
177   - 还差<text class="word-color">{{prom_act.max_ct_num - item.open_num}}</text>人享最低优惠</text>
178   - <text wx:else>您已经享最低优惠</text>
179   - </text>
  175 + <text class='gred' wx:if="{{prom_act.max_ct_num >0}}"><text class="flex" wx:if="{{prom_act.max_ct_num - item.open_num>0}}">还差<text class="word-color">{{prom_act.max_ct_num - item.open_num}}</text>人享最低优惠</text><text wx:else>您已经享最低优惠</text></text>
180 176 <text class='gred' wx:else>还差<text style='color:#ff2753'>{{prom_act.ct_num - item.open_num}}</text>人成团 </text>
181 177 <view class="t_show">
182 178 剩余
... ...
pages/goods/goodsInfo/goodsInfo.wxss
... ... @@ -831,7 +831,7 @@ left:31rpx;}
831 831 .group .group-list .ghaicha {
832 832 width:300rpx;
833 833 font-size: 27rpx;
834   - margin-left:100px;
  834 + margin-left:180rpx;
835 835 top:13rpx;
836 836 left:-3rpx;
837 837 font-weight:600;
... ...
pages/goods/goodsList/goodsList.js
... ... @@ -67,6 +67,7 @@ Page({
67 67 t +="&page=" + e.data.currentPage,
68 68 a.request(t,
69 69 function(t) {
  70 + e.setData({is_go:1});
70 71 e.data.currentPage++, null == e.data.allData && (e.data.allData = Object.assign({}, t.data.result)),
71 72 wx.stopPullDownRefresh();
72 73 },
... ...
pages/goods/goodsList/goodsList.wxml
... ... @@ -42,7 +42,7 @@
42 42 </view>
43 43 </navigator>
44 44 </view>
45   - <view class="no-data" wx:if="{{!requestData||requestData.length==0}}">
  45 + <view class="no-data" wx:if="{{(!requestData||requestData.length==0) && is_go}}">
46 46 <image class="cart-image" src="{{iurl}}/miniapp/images/cart-null.png"></image>
47 47 <view class="no-data-title">没有相关的数据</view>
48 48 <navigator class="lookat" openType="switchTab" url="/pages/index/index/index"> 去逛逛 </navigator>
... ...
pages/team/team_ping/team_ping.js
... ... @@ -156,7 +156,7 @@ Page({
156 156 })
157 157  
158 158 //--正在进行中的团,才有时间倒计时--
159   - if(teamgroup.state==2) {
  159 + if(teamgroup && teamgroup.state==2) {
160 160 order[i].kt_end_time = teamgroup.kt_end_time;
161 161 //---如果参团的人数没有3个人,则要体现沙发---
162 162 order[i].tg_state = teamgroup.state;
... ...
pages/team/team_ping/team_ping.wxml
... ... @@ -80,10 +80,9 @@
80 80 </view>
81 81  
82 82 <view class='C'>
83   - <view class='yao' wx:if="{{item.pt_status==1}}">邀请好友</view>
84   -
85   - <view class='s_and_f' wx:if="{{item.pt_status==2 || item.pt_status==4 || item.pt_status==5 }}">查看详情</view>
86   - <view class='s_and_f' wx:if="{{item.pt_status==3}}">查看详情</view>
  83 + <view class='yao' wx:if="{{item.pt_status==1}}">邀请好友</view>
  84 + <view class='s_and_f' wx:if="{{item.pt_status==2 || item.pt_status==4 || item.pt_status==5 }}">查看详情</view>
  85 + <view class='s_and_f' wx:if="{{item.pt_status==3}}">查看详情</view>
87 86 </view>
88 87  
89 88 </view>
... ...
pages/team/team_show/team_show.js
... ... @@ -40,7 +40,7 @@ Page({
40 40 teamgroup: null, //活动从表
41 41 goods: null, //商品数据
42 42 pindGoods: null, //拼单数据
43   - imageurl: "https://mshopimg.yolipai.net/", //有礼派图片地址
  43 + imageurl: os.imghost, //有礼派图片地址
44 44 team_id: 0, //支付是否成功
45 45 listno: "", //订单编号
46 46  
... ... @@ -156,6 +156,8 @@ Page({
156 156 clist: function(e) {
157 157 var i = e.currentTarget.dataset.end;
158 158 var pick_id = e.currentTarget.dataset.pick_id;
  159 + var pick_dis = e.currentTarget.dataset.pick_dis;
  160 +
159 161 this.setData({
160 162 end_name: i,
161 163 pick_id: pick_id,
... ... @@ -163,8 +165,10 @@ Page({
163 165 qh: true,
164 166 se: false,
165 167 list: false,
  168 + pick_dis: pick_dis
166 169 })
167 170 },
  171 +
168 172 //点击第一层
169 173 setchild: function(e) {
170 174 var ind = e.currentTarget.dataset.bindex;
... ... @@ -649,6 +653,8 @@ Page({
649 653 //------去支付,购买-------
650 654 go_pay:function () {
651 655 var th=this;
  656 + if (th.data.pick_id == 0) return s.my_warnning("请选择门店", 0, th);
  657 +
652 658 //----判断起购数----
653 659 var qnum=parseFloat(th.data.teamlist.minbuynum);
654 660 if(qnum>0 && qnum>th.data.num ){
... ... @@ -703,6 +709,8 @@ Page({
703 709 }
704 710 break;
705 711 }
  712 + newd['pick_dis'] = th.data.pick_dis;
  713 +
706 714 s.set_b_now(newd);
707 715  
708 716 wx.navigateTo({
... ...
pages/team/team_show/team_show.json
... ... @@ -5,5 +5,8 @@
5 5 "navigationBarTextStyle": "white",
6 6 "navigationBarBackgroundColor": "#ffffff",
7 7 "backgroundColor": "#eeeeee"
  8 + },
  9 + "usingComponents": {
  10 + "warn": "/components/long_warn/long_warn"
8 11 }
9 12 }
10 13 \ No newline at end of file
... ...
pages/team/team_show/team_show.wxml
... ... @@ -136,8 +136,6 @@
136 136 <!----收起拼团列表---->
137 137 <view class='zhangxi' wx:if="{{hiddenName}}">
138 138  
139   -
140   -
141 139 <view class='zspan' bindtap='click'>收起拼团列表
142 140 <view class='down-arrow1'></view>
143 141 </view>
... ... @@ -222,7 +220,9 @@
222 220 <!--第二层list-->
223 221 <block wx:if="{{list}}">
224 222 <scroll-view scroll-y="true" style="max-height: 460rpx">
225   - <view class='xuanze' wx:for="{{ssl_child}}" wx:key bindtap='clist' data-end='{{item.pickup_name}}' data-pick_id='{{item.pickup_id}}'>
  223 + <view class='xuanze' wx:for="{{ssl_child}}" wx:key bindtap='clist'
  224 + data-pick_dis="{{item.distr_type}}"
  225 + data-end='{{item.pickup_name}}' data-pick_id='{{item.pickup_id}}'>
226 226 <text decode='true'>{{item.pickup_name}}</text>
227 227 </view>
228 228 </scroll-view>
... ... @@ -281,4 +281,6 @@
281 281 </view>
282 282 </view>
283 283 </view>
284   -</block>
285 284 \ No newline at end of file
  285 +</block>
  286 +
  287 +<warn id="warn"></warn>
286 288 \ No newline at end of file
... ...
pages/team/team_success/team_success.js
... ... @@ -102,7 +102,10 @@ Page({
102 102 },
103 103  
104 104 async init( order_sn) {
105   - var goods_id = 0,//商品ID,
  105 +
  106 + wx.showLoading();
  107 +
  108 + var goods_id = 0,//商品ID,
106 109 pageteam=null,//
107 110 original_img=null ,//商品图片
108 111 order=null,//订单编号
... ... @@ -212,8 +215,10 @@ Page({
212 215 data: { store_id: os.stoid, listno: pt_listno, team_id: pt_prom_id }
213 216 }).then(res => {
214 217 teamgroup = res.data.data.pageData[0];
215   - var buy_start_date = ut.formatTime(teamgroup.buy_start_date, "yyyy-MM-dd hh:mm:ss");
216   - teamgroup.buy_start_date=buy_start_date;
  218 + if (teamgroup){
  219 + var buy_start_date = ut.formatTime(teamgroup.buy_start_date, "yyyy-MM-dd hh:mm:ss");
  220 + teamgroup.buy_start_date=buy_start_date;
  221 + }
217 222 })
218 223  
219 224  
... ... @@ -222,7 +227,7 @@ Page({
222 227 if (teamlist.kttype == 3){
223 228 var js_data = JSON.parse(teamlist.ct_rylist);
224 229 js_data.forEach(function (val,ind) {
225   - if (num_0<val.rynum && ct_price==0){
  230 + if (num_0<=val.rynum && ct_price==0){
226 231 ct_price=val.price;
227 232 }
228 233 })
... ... @@ -260,6 +265,8 @@ Page({
260 265 ct_price: ct_price, p_status: p_status,sf_arr:sf_arr});
261 266 }
262 267  
  268 + wx.hideLoading();
  269 +
263 270 wx.setNavigationBarTitle({
264 271 title: "拼团详情",
265 272 })
... ... @@ -505,33 +512,34 @@ Page({
505 512  
506 513 //把画板内容绘制成图片,并回调 画板图片路径
507 514 context.draw(false, function () {
508   - console.log('draw callback')
509   - wx.canvasToTempFilePath({
510   - x: 0, y: 0,
511   - width: 750,
512   - height: 1217,
513   - destWidth: 750 * 750 / that.data.screenWidth,
514   - destHeight: 1217 * 750 / that.data.screenWidth,
515   - canvasId: 'share',
516   - success: function (res) {
517   - that.setData({
518   - shareImgPath: res.tempFilePath, canvasHidden: false,
519   - })
520   - if (!res.tempFilePath) {
521   - wx.showModal({
522   - title: '提示',
523   - content: '图片绘制中,请稍后重试',
524   - showCancel: false
  515 + setTimeout(function () {
  516 + wx.canvasToTempFilePath({
  517 + x: 0, y: 0,
  518 + width: 750,
  519 + height: 1217,
  520 + destWidth: 750 * 750 / that.data.screenWidth,
  521 + destHeight: 1217 * 750 / that.data.screenWidth,
  522 + canvasId: 'share',
  523 + success: function (res) {
  524 + that.setData({
  525 + shareImgPath: res.tempFilePath, canvasHidden: false,
525 526 })
526   - return false;
  527 + if (!res.tempFilePath) {
  528 + wx.showModal({
  529 + title: '提示',
  530 + content: '图片绘制中,请稍后重试',
  531 + showCancel: false
  532 + })
  533 + return false;
  534 + }
  535 + wx.previewImage({
  536 + //将图片预览出来
  537 + urls: [that.data.shareImgPath]
  538 + });
  539 + wx.hideLoading();
527 540 }
528   - wx.previewImage({
529   - //将图片预览出来
530   - urls: [that.data.shareImgPath]
531   - });
532   - wx.hideLoading();
533   - }
534   - })
  541 + })
  542 + },200)
535 543 });
536 544 });
537 545 }
... ... @@ -619,6 +627,7 @@ Page({
619 627 });
620 628 }
621 629 },
  630 +
622 631 //--获取商品图片的本地缓存,回调写法--
623 632 get_goods_temp:function (tt) {
624 633 var ee=this;
... ...
pages/team/team_success/team_success.wxml
... ... @@ -70,12 +70,12 @@
70 70 <view class='bodytop' wx:if="{{(teamlist.kttype==2 || teamlist.kttype==1) && p_status==1}}">
71 71 还差
72 72 <text class="xc-wc">{{teamlist.ct_num-ordertx.length}}</text>人成团,组团成功为您节省
73   - <text class="xc-wc">{{goods.market_price-teamlist.price}}</text>元
  73 + <text class="xc-wc">{{filters.toFix(goods.market_price-teamlist.price,2)}}</text>元
74 74 </view>
75 75 <!-- 拼团成功 -->
76 76 <view class="xc-ptcomplete flex-level fs28" wx:if="{{p_status==2 && (teamlist.kttype==2||teamlist.kttype==1)}}">
77 77 <view class="xc-wc">拼团成功</view>,为您节省
78   - <text class="xc-wc">{{goods.market_price-teamlist.price}}</text>元
  78 + <text class="xc-wc">{{filters.toFix(goods.market_price-teamlist.price,2)}}</text>元
79 79 <view class="xc-img-frame oh">
80 80 <image class="img" src="{{iurl}}/miniapp/images/xc_qtcg.png"></image>
81 81 </view>
... ... @@ -152,7 +152,7 @@
152 152 <!-- <block wx:if="{{pay_f!=1 && order.pt_status<2}}"> -->
153 153 <!----/ // // // //按钮---->
154 154  
155   - <view wx:if="{{teamlist.kttype==3}}" class='bodybutton' bindtap='cmeng'>
  155 + <view wx:if="{{teamlist.kttype==3}}" style='background-color:#fab55a; color:#fff' class='bodybutton' bindtap='cmeng'>
156 156 <!-- 阶梯团 -->
157 157 <button wx:if="{{p_status==1}}">
158 158 邀请好友参团
... ...
pages/user/grow_value/grow_value.json
1 1 {
2   - "navigationBarTitleText": "我的成长值",
  2 + "navigationBarTitleText": "我的成长值",
3 3 "usingComponents": {
4 4 "timePicker": "/components/timePicker/timePicker",
5 5 "warn": "/components/long_warn/long_warn"
... ...
pages/user/index/index.wxml
... ... @@ -167,7 +167,7 @@
167 167 <view class="fs26">秒杀活动</view>
168 168 </view>
169 169 <view class="item t-c" bindtap="go_qy" wx:if="{{qy_list!=null && is_init && gradeId}}">
170   - <image class="xc-center-img " src="{{iurl}}/miniapp/images/equity.png"></image>
  170 + <image class="xc-center-img " src="/images/quanyi2.png"></image>
171 171 <view class="fs26">我的权益</view>
172 172 </view>
173 173  
... ... @@ -182,16 +182,16 @@
182 182 <view class="fs26">收藏夹</view>
183 183 </view>
184 184  
185   - <!--<view class="item t-c">-->
186   - <!--<image class="xc-center-img " src="{{iurl}}/miniapp/images/fuwu.png"></image>-->
187   - <!--<view class="four-level-word">我的服务</view>-->
188   - <!--</view>-->
189   -
190 185 <view class="item t-c" data-url="/pages/user/comment/comment" bindtap="goto" >
191 186 <image class="xc-center-img " src="{{iurl}}/miniapp/images/evaluate.png"></image>
192 187 <view class="fs26">我的评价</view>
193 188 </view>
194 189  
  190 + <view class="item t-c" data-url="/pages/user/address_list/address_list" bindtap="goto" >
  191 + <image class="xc-center-img " src="/images/add2.png"></image>
  192 + <view class="four-level-word">我的地址</view>
  193 + </view>
  194 +
195 195 </view>
196 196  
197 197  
... ...
pages/user/member/account/account.wxml
... ... @@ -53,7 +53,7 @@
53 53  
54 54 <view class="money"
55 55 style="color:{{details.type==2||details.type==0?'#C4182E':'#6fd137'}}">
56   - {{details.type==2||details.type==0?'+':'-'}}{{filter.getNum(details.money)}}</view>
  56 + {{details.type==1||details.type==3?'-':'+'}}{{filter.getNum(details.money)}}</view>
57 57 </view>
58 58 </block>
59 59  
... ...
pages/user/order_detail/order_detail.wxml
... ... @@ -28,7 +28,7 @@
28 28 </navigator>
29 29 <view class="order-num">
30 30 <view class="goods-price">¥{{item.member_goods_price}}</view>
31   - <view class="goods-num">{{item.goods_num}}</view>
  31 + <view class="goods-num">×{{item.goods_num}}</view>
32 32 </view>
33 33 </view>
34 34 <view class="order-operate">
... ...
project.config.json
... ... @@ -14,8 +14,8 @@
14 14 },
15 15 "compileType": "miniprogram",
16 16 "libVersion": "2.2.4",
17   - "appid": "wx2ea7cdd3ef52cdff",
18   - "projectname": "miaosha",
  17 + "appid": "wx7406a86b64b58a1d",
  18 + "projectname": "QA_MShopWeApp",
19 19 "debugOptions": {
20 20 "hidedInDevtools": []
21 21 },
... ...
setting.js
1 1 module.exports = {
2   - appName: "派派通",
3   - versionCode: "1.0.0",
4   - appLogo: "../../../images/logo.png",
5   - url: "https://test-weshop.yolipai.net",
6   - //url:"https://weshop.yolipai.net", //外网的网址
7   - //url:"http://172.20.3.121:8085", //明海的网址
8   - //url:"http://172.20.3.102:8085", //自己的网址
9   - banner_err:"../../../images/del/logo.png",
10   - imghost: "https://mshopimg.yolipai.net/",
11   - share: {},
12   - stoid:1,
13   -
14   -};
  2 + appName: "美得得商户中心",
  3 + versionCode: "1.3.1",
  4 + appLogo: "../../../images/logo.png",
  5 + url: "https://weshop.yolipai.net",
  6 + banner_err: "../../../images/del/logo.png",
  7 + imghost: "https://mshopimg.yolipai.net/",
  8 + share: {},
  9 + stoid: 197,
  10 +};
15 11 \ No newline at end of file
... ...
utils/filter.wxs
... ... @@ -18,7 +18,7 @@ var filters = {
18 18 if(isFull==1)
19 19 fm=fm + ' '+ [d.getHours(), d.getMinutes(), d.getSeconds()].join(':')
20 20 return fm;
21   - }
  21 + },
22 22  
23 23 pInt:function(t) {
24 24 var d = parseInt(t); return d;
... ...