Commit 4070f44c301cd4eac1e23500c1e4b7056a11b839
1 parent
6898e916
oa单测试返回
Showing
7 changed files
with
40 additions
and
28 deletions
packageA/pages/quan_pro/quan_pro.wxml
| @@ -16,9 +16,9 @@ | @@ -16,9 +16,9 @@ | ||
| 16 | <view class="fs30 flex" wx:if="{{q_data}}" style="height: 100rpx;justify-content: space-between;"> | 16 | <view class="fs30 flex" wx:if="{{q_data}}" style="height: 100rpx;justify-content: space-between;"> |
| 17 | <view class="flex ai-center"> | 17 | <view class="flex ai-center"> |
| 18 | <view class="t_circle"></view> | 18 | <view class="t_circle"></view> |
| 19 | - <view> | 19 | + <view class="ellipsis-2" style="width: 400rpx;"> |
| 20 | <text wx:if="{{q_data.useobjecttype==0}}">全场通用</text> | 20 | <text wx:if="{{q_data.useobjecttype==0}}">全场通用</text> |
| 21 | - <text wx:else>仅限{{q_data.useobjectname}}使用</text> | 21 | + <text wx:else >仅限{{q_data.useobjectname}}使用</text> |
| 22 | </view> | 22 | </view> |
| 23 | </view> | 23 | </view> |
| 24 | <view> | 24 | <view> |
packageA/pages/quan_pro/quan_pro.wxss
| @@ -10,7 +10,7 @@ page{background-color: #f8f8f8;} | @@ -10,7 +10,7 @@ page{background-color: #f8f8f8;} | ||
| 10 | .q_content{ position: absolute;top: 0; left: 0; width: calc(100% - 40rpx); height: 450rpx;padding: 0 20rpx; } | 10 | .q_content{ position: absolute;top: 0; left: 0; width: calc(100% - 40rpx); height: 450rpx;padding: 0 20rpx; } |
| 11 | .upper{ height:330rpx;} | 11 | .upper{ height:330rpx;} |
| 12 | .lower{ height: 120rpx; line-height: 170rpx;color:#7a668f} | 12 | .lower{ height: 120rpx; line-height: 170rpx;color:#7a668f} |
| 13 | -.quan_box {display: flex;flex-direction: column;justify-content: flex-start; box-sizing: border-box;} | 13 | +.quan_box {display: flex;flex-direction: column; box-sizing: border-box;} |
| 14 | .upper .left{ margin-left:30rpx; margin-top: 30rpx } | 14 | .upper .left{ margin-left:30rpx; margin-top: 30rpx } |
| 15 | .t_circle{ width: 10rpx; height: 10rpx; border-radius: 50%; background-color: #fff; margin-right: 8rpx} | 15 | .t_circle{ width: 10rpx; height: 10rpx; border-radius: 50%; background-color: #fff; margin-right: 8rpx} |
| 16 | 16 | ||
| @@ -27,5 +27,5 @@ page{background-color: #f8f8f8;} | @@ -27,5 +27,5 @@ page{background-color: #f8f8f8;} | ||
| 27 | } | 27 | } |
| 28 | 28 | ||
| 29 | .btn.gray{background-color: #dcdcdc; color: #adb3be;} | 29 | .btn.gray{background-color: #dcdcdc; color: #adb3be;} |
| 30 | -.coupon_remark{padding: 20rpx 0; box-sizing: border-box; overflow: hidden;} | 30 | +.coupon_remark{padding: 30rpx 0 10rpx 0; box-sizing: border-box; overflow: hidden;} |
| 31 | 31 |
packageB/pages/zuhegou/index/index.js
| @@ -1990,11 +1990,12 @@ Page({ | @@ -1990,11 +1990,12 @@ Page({ | ||
| 1990 | // be=be-bz_num_ok; | 1990 | // be=be-bz_num_ok; |
| 1991 | if(num % vv.zhqty == 0){ | 1991 | if(num % vv.zhqty == 0){ |
| 1992 | be=num/vv.zhqty; | 1992 | be=num/vv.zhqty; |
| 1993 | - bz_num_ok=num; | 1993 | + // bz_num_ok=num; |
| 1994 | }else{ | 1994 | }else{ |
| 1995 | be = Math.floor(num/vv.zhqty) | 1995 | be = Math.floor(num/vv.zhqty) |
| 1996 | - bz_num_ok=num - (be * vv.zhqty); | 1996 | + // bz_num_ok=be * vv.zhqty ; |
| 1997 | } | 1997 | } |
| 1998 | + bz_num_ok=be * vv.zhqty ; | ||
| 1998 | } | 1999 | } |
| 1999 | for(let i=0;i<zhqty_bz.length;i++){ | 2000 | for(let i=0;i<zhqty_bz.length;i++){ |
| 2000 | var vv=zhqty_bz[i]; | 2001 | var vv=zhqty_bz[i]; |
| @@ -2024,13 +2025,13 @@ Page({ | @@ -2024,13 +2025,13 @@ Page({ | ||
| 2024 | // be=be-bz_num_ok; | 2025 | // be=be-bz_num_ok; |
| 2025 | if(num % vv.zhqty == 0){ | 2026 | if(num % vv.zhqty == 0){ |
| 2026 | be=num/vv.zhqty; | 2027 | be=num/vv.zhqty; |
| 2027 | - bz_num_ok=num; | 2028 | + // bz_num_ok=num; |
| 2028 | }else{ | 2029 | }else{ |
| 2029 | be = Math.floor(num/vv.zhqty) | 2030 | be = Math.floor(num/vv.zhqty) |
| 2030 | - bz_num_ok=num - (be * vv.zhqty); | 2031 | + // bz_num_ok=be * vv.zhqty; |
| 2031 | } | 2032 | } |
| 2033 | + bz_num_ok=be * vv.zhqty; | ||
| 2032 | } | 2034 | } |
| 2033 | - // be=vv.num; | ||
| 2034 | for(let j=0;j<bz_num_ok;j++){ | 2035 | for(let j=0;j<bz_num_ok;j++){ |
| 2035 | let index= no_in_arr.findIndex(i=>{ | 2036 | let index= no_in_arr.findIndex(i=>{ |
| 2036 | return vv.goods_id===i.goods_id | 2037 | return vv.goods_id===i.goods_id |
packageB/pages/zuhegou/list/list.js
| @@ -137,7 +137,7 @@ Page({ | @@ -137,7 +137,7 @@ Page({ | ||
| 137 | isShowLoading:1, | 137 | isShowLoading:1, |
| 138 | data:{ | 138 | data:{ |
| 139 | store_id: os.stoid, | 139 | store_id: os.stoid, |
| 140 | - user_id: getApp().globalData.user_id | 140 | + user_id: getApp().globalData.user_id, |
| 141 | } | 141 | } |
| 142 | }) | 142 | }) |
| 143 | if(res.code==0 && res.data.pageData.length>0){ | 143 | if(res.code==0 && res.data.pageData.length>0){ |
pages/activity/pind_list/pind_list.js
| @@ -61,7 +61,12 @@ Page({ | @@ -61,7 +61,12 @@ Page({ | ||
| 61 | }); | 61 | }); |
| 62 | } | 62 | } |
| 63 | }) | 63 | }) |
| 64 | - | 64 | + // var user_id=getApp().globalData.user_id; |
| 65 | + // if(!user_id) user_id=0; | ||
| 66 | + // this.setData({ | ||
| 67 | + // user_id, | ||
| 68 | + // }) | ||
| 69 | + this.requestSalelist(); | ||
| 65 | }, | 70 | }, |
| 66 | 71 | ||
| 67 | onShow: function (t) { | 72 | onShow: function (t) { |
| @@ -69,13 +74,15 @@ Page({ | @@ -69,13 +74,15 @@ Page({ | ||
| 69 | this.data.currentPage = 1; | 74 | this.data.currentPage = 1; |
| 70 | this.data.ismore = 1; | 75 | this.data.ismore = 1; |
| 71 | var th = this; | 76 | var th = this; |
| 72 | - var userInfo = wx.getStorageSync('userinfo'); | ||
| 73 | - if (userInfo && th.data.goodlist.length==0) { | ||
| 74 | - //调用列表 | ||
| 75 | - this.requestSalelist(userInfo.user_id); | ||
| 76 | - } else { | ||
| 77 | - getApp().goto("/pages/togoin/togoin"); | ||
| 78 | - } | 77 | + // var userInfo = wx.getStorageSync('userinfo'); |
| 78 | + // if (userInfo) { | ||
| 79 | + // //调用列表 | ||
| 80 | + // this.requestSalelist(userInfo.user_id); | ||
| 81 | + // } else { | ||
| 82 | + // getApp().goto("/pages/togoin/togoin"); | ||
| 83 | + // } | ||
| 84 | + | ||
| 85 | + | ||
| 79 | //设置全局定时器 | 86 | //设置全局定时器 |
| 80 | th.data.timer = setInterval(function () { | 87 | th.data.timer = setInterval(function () { |
| 81 | th.countDown(); | 88 | th.countDown(); |
| @@ -129,7 +136,7 @@ Page({ | @@ -129,7 +136,7 @@ Page({ | ||
| 129 | }, | 136 | }, |
| 130 | 137 | ||
| 131 | //读取数据 | 138 | //读取数据 |
| 132 | - async requestSalelist(user_id) { | 139 | + async requestSalelist() { |
| 133 | if (!this.data.ismore) return false; | 140 | if (!this.data.ismore) return false; |
| 134 | var e = this, | 141 | var e = this, |
| 135 | th = e, | 142 | th = e, |
| @@ -143,7 +150,7 @@ Page({ | @@ -143,7 +150,7 @@ Page({ | ||
| 143 | store_id: os.stoid, | 150 | store_id: os.stoid, |
| 144 | is_end: 0, | 151 | is_end: 0, |
| 145 | is_show: 1, | 152 | is_show: 1, |
| 146 | - user_id, | 153 | + user_id:getApp().globalData.user_id, |
| 147 | } | 154 | } |
| 148 | }).then(res => { | 155 | }).then(res => { |
| 149 | plist = res.data.data.pageData; | 156 | plist = res.data.data.pageData; |
| @@ -178,7 +185,7 @@ Page({ | @@ -178,7 +185,7 @@ Page({ | ||
| 178 | this.reloadGoodList(); | 185 | this.reloadGoodList(); |
| 179 | }, | 186 | }, |
| 180 | reloadGoodList: function () { | 187 | reloadGoodList: function () { |
| 181 | - this.data.goodlist = null, this.data.currentPage = 1, this.requestSalelist(); | 188 | + this.data.goodlist = [], this.data.currentPage = 1, this.requestSalelist(); |
| 182 | }, | 189 | }, |
| 183 | onReachBottom: function () { | 190 | onReachBottom: function () { |
| 184 | this.requestSalelist(); | 191 | this.requestSalelist(); |
pages/activity/seckill_list/seckill_list.js
pages/cart/cart2/cart2.js
| @@ -1542,7 +1542,7 @@ Page({ | @@ -1542,7 +1542,7 @@ Page({ | ||
| 1542 | cart_item.shipping_price = 0; | 1542 | cart_item.shipping_price = 0; |
| 1543 | 1543 | ||
| 1544 | //--有不包邮区域,且不免运费,全场的计算,要减到优惠金额 和券的金额-- | 1544 | //--有不包邮区域,且不免运费,全场的计算,要减到优惠金额 和券的金额-- |
| 1545 | - if (no_ex_id && freight_free > 0 && (o_price - quan_price) >= freight_free && cart_item.exp_type == 0 && (by_qc.region_list || by_qc.goods_list) && out_of_weight > 0) { | 1545 | + if (no_ex_id && freight_free > 0 && (o_price - quan_price) >= freight_free && cart_item.exp_type == 0 && (by_qc.region_list || by_qc.goods_list) && out_of_weight >= 0) { |
| 1546 | //如果有设置不包邮区域的时候 | 1546 | //如果有设置不包邮区域的时候 |
| 1547 | if (by_qc.region_list != "" && by_qc.region_list != null && by_qc.region_list != undefined) { | 1547 | if (by_qc.region_list != "" && by_qc.region_list != null && by_qc.region_list != undefined) { |
| 1548 | if (th.check_by_area(by_qc.region_list)) { | 1548 | if (th.check_by_area(by_qc.region_list)) { |
| @@ -2481,8 +2481,8 @@ Page({ | @@ -2481,8 +2481,8 @@ Page({ | ||
| 2481 | //调用接口判断是不是会员 | 2481 | //调用接口判断是不是会员 |
| 2482 | await getApp().request.promiseGet("/api/weshop/shoppingGuide/getId/" + oo.stoid + "/" + gg.guide_id, {}).then(res => { | 2482 | await getApp().request.promiseGet("/api/weshop/shoppingGuide/getId/" + oo.stoid + "/" + gg.guide_id, {}).then(res => { |
| 2483 | if (res.data.code == 0) { | 2483 | if (res.data.code == 0) { |
| 2484 | - g_goods.guide_name = is_vip.salesman; | ||
| 2485 | - g_goods.guide_sn = is_vip.salesman_no; | 2484 | + g_goods.guide_name = res.data.salesman; |
| 2485 | + g_goods.guide_sn = res.data.salesman_no; | ||
| 2486 | } | 2486 | } |
| 2487 | }) | 2487 | }) |
| 2488 | } | 2488 | } |
| @@ -3037,7 +3037,7 @@ Page({ | @@ -3037,7 +3037,7 @@ Page({ | ||
| 3037 | var price = 0, th = this; | 3037 | var price = 0, th = this; |
| 3038 | price += parseFloat(o_shipping_price); | 3038 | price += parseFloat(o_shipping_price); |
| 3039 | //如果是包邮 | 3039 | //如果是包邮 |
| 3040 | - if (freight_free > 0 && o_price >= freight_free && out_of_weight>0) { | 3040 | + if (freight_free > 0 && o_price >= freight_free && out_of_weight>=0) { |
| 3041 | return 0; | 3041 | return 0; |
| 3042 | } | 3042 | } |
| 3043 | if (user_addr == null) { | 3043 | if (user_addr == null) { |
| @@ -3067,8 +3067,13 @@ Page({ | @@ -3067,8 +3067,13 @@ Page({ | ||
| 3067 | if(out_of_weight < 0){ | 3067 | if(out_of_weight < 0){ |
| 3068 | fw_price = parseFloat(item['money']); | 3068 | fw_price = parseFloat(item['money']); |
| 3069 | var out_of_weight = Math.abs(out_of_weight); | 3069 | var out_of_weight = Math.abs(out_of_weight); |
| 3070 | - var n = Math.ceil(out_of_weight / item['second_weight']) | ||
| 3071 | - fw_price = fw_price + n * parseFloat(item['add_money']); | 3070 | + // var n = Math.ceil(out_of_weight / item['second_weight']) |
| 3071 | + // fw_price = fw_price + n * parseFloat(item['add_money']); | ||
| 3072 | + if (out_of_weight > item['first_weight']) { | ||
| 3073 | + var fw = out_of_weight - item['first_weight']; | ||
| 3074 | + var n = Math.ceil(fw / item['second_weight']) | ||
| 3075 | + fw_price = fw_price + n * parseFloat(item['add_money']); | ||
| 3076 | + } | ||
| 3072 | } | 3077 | } |
| 3073 | //------按件数---------- | 3078 | //------按件数---------- |
| 3074 | if (goods_piece > 0 && item['piecemoney']) { | 3079 | if (goods_piece > 0 && item['piecemoney']) { |