Commit f6fea19755568a333b8d1d4297dc09f81ffd4155
Merge branch 'qa' of http://git.vipzhuang.cn/wxd/MShopWeApp
Showing
4 changed files
with
36 additions
and
8 deletions
components/diy_top_nav/diy_top_nav.js
components/diy_top_nav/diy_top_nav.wxml
... | ... | @@ -55,7 +55,7 @@ |
55 | 55 | </view> |
56 | 56 | <view wx:if="{{!istop}}" catchtap="nav_search" class="navl_minddle ellipsis-1" style="margin: 0 {{navleft_pb}}px;display: block"> |
57 | 57 | <icon type="search" size="28rpx" color="#898989" class="sear_fangda" /> |
58 | - <text>搜索更多商品</text> | |
58 | + <text>搜索商品</text> | |
59 | 59 | </view> |
60 | 60 | <view wx:else ></view> |
61 | 61 | <view wx:if="{{is_share}}" class="navl_right" catchtap="fenx_fn" style="height:{{mentButt_h}}px;width:{{mentButt_h}}px;"> | ... | ... |
pages/user/order_detail/order_detail.js
... | ... | @@ -177,6 +177,7 @@ Page({ |
177 | 177 | if(res.data.code == 0 && res.data.data){ |
178 | 178 | r.use_commission=res.data.data.use_commission; |
179 | 179 | r.pre_cut=res.data.data.pre_cut; //预存款 |
180 | + r.pre_json=res.data.data.pre_json; //预存款 | |
180 | 181 | } |
181 | 182 | }) |
182 | 183 | |
... | ... | @@ -375,6 +376,33 @@ Page({ |
375 | 376 | }); |
376 | 377 | }, |
377 | 378 | |
379 | + //-- 预存款判断 -- | |
380 | + async vipadvancesum(keyid,pre_cut,pre_json){ | |
381 | + let pre=JSON.parse(pre_json) | |
382 | + let listform=[] | |
383 | + pre.map(item=>{ | |
384 | + let obj={ | |
385 | + advancesum: item.advancesum, | |
386 | + advanceitemid: item.advanceitemid | |
387 | + } | |
388 | + listform.push(obj) | |
389 | + }) | |
390 | + let res = await getApp().request.promisePost(`/api/weshop/delphiapi/saveErpApi`, { | |
391 | + data: { | |
392 | + accdb: getApp().globalData.config.erpid, | |
393 | + ApiName: 'api.pos.shop.vipadvancesum.list', | |
394 | + // usercode: "admin", | |
395 | + vipid: getApp().globalData.userInfo.erpvipid, | |
396 | + // oddsum: "0", | |
397 | + // advancesum: cartList.order_amount, | |
398 | + storageid: keyid, | |
399 | + listform | |
400 | + }, | |
401 | + is_json: 1 | |
402 | + }) | |
403 | + return res.data | |
404 | + }, | |
405 | + | |
378 | 406 | //--------立即支付---------- |
379 | 407 | async jumpToCart4(e) { |
380 | 408 | |
... | ... | @@ -443,7 +471,7 @@ Page({ |
443 | 471 | } |
444 | 472 | |
445 | 473 | if(res1.data.data.length<=0){ |
446 | - getApp().confirmBox("获取预存的金额失败"); | |
474 | + getApp().confirmBox("每天每人仅能使用1次预存抵扣"); | |
447 | 475 | th.setData({ paying: 0 }); |
448 | 476 | return false; |
449 | 477 | } |
... | ... | @@ -454,12 +482,12 @@ Page({ |
454 | 482 | yck += ite.advancesum*1 |
455 | 483 | }) |
456 | 484 | if(yck<=0){ |
457 | - getApp().confirmBox("获取预存的金额失败"); | |
485 | + getApp().confirmBox("每天每人仅能使用1次预存抵扣"); | |
458 | 486 | th.setData({ paying: 0 }); |
459 | 487 | return false; |
460 | 488 | } |
461 | 489 | |
462 | - if(pre_cut && yck!=pre_cut){ | |
490 | + if(order.pre_cut && yck!=order.pre_cut){ | |
463 | 491 | getApp().confirmBox("获取预存的金额不对"); |
464 | 492 | th.setData({ paying: 0 }); |
465 | 493 | return false; | ... | ... |
pages/user/order_list/order_list.js
... | ... | @@ -757,7 +757,7 @@ Page({ |
757 | 757 | } |
758 | 758 | |
759 | 759 | if(res1.data.data.length<=0){ |
760 | - getApp().confirmBox("获取预存的金额失败"); | |
760 | + getApp().confirmBox("每天每人仅能使用1次预存抵扣"); | |
761 | 761 | th.setData({ paying: 0 }); |
762 | 762 | return false; |
763 | 763 | } |
... | ... | @@ -768,12 +768,12 @@ Page({ |
768 | 768 | yck += ite.advancesum*1 |
769 | 769 | }) |
770 | 770 | if(yck<=0){ |
771 | - getApp().confirmBox("获取预存的金额失败"); | |
771 | + getApp().confirmBox("每天每人仅能使用1次预存抵扣"); | |
772 | 772 | th.setData({ paying: 0 }); |
773 | 773 | return false; |
774 | 774 | } |
775 | 775 | |
776 | - if(pre_cut && yck!=pre_cut){ | |
776 | + if(order.pre_cut && yck!=order.pre_cut){ | |
777 | 777 | getApp().confirmBox("获取预存的金额不对"); |
778 | 778 | th.setData({ paying: 0 }); |
779 | 779 | return false; | ... | ... |