Commit ef7d5b26eb6f88b8b76a6c7bb6122ebef5af31f6
1 parent
cdddaf7a
组合购的优化
Showing
2 changed files
with
2 additions
and
2 deletions
packageE/pages/cart/cart2/zh_calculate.js
@@ -158,7 +158,7 @@ module.exports = { | @@ -158,7 +158,7 @@ module.exports = { | ||
158 | let be = parseInt(no_in_arr.length / act.zhbuyqty); | 158 | let be = parseInt(no_in_arr.length / act.zhbuyqty); |
159 | //如果有总数控制的时候,看还能买几组 | 159 | //如果有总数控制的时候,看还能买几组 |
160 | if(act.zh_num){ | 160 | if(act.zh_num){ |
161 | - var be1= parseInt((act.zh_num-act.zh_buy_num)/ act.zhbuyqty)-1; | 161 | + var be1= parseInt(act.zh_num-act.zh_buy_num)-1; |
162 | if(be1<be) be=be1; | 162 | if(be1<be) be=be1; |
163 | } | 163 | } |
164 | 164 |
pages/cart/cart/zh_calculate.js
@@ -242,7 +242,7 @@ module.exports = { | @@ -242,7 +242,7 @@ module.exports = { | ||
242 | 242 | ||
243 | //如果有总数控制的时候,看还能买几组 | 243 | //如果有总数控制的时候,看还能买几组 |
244 | if(act.zh_num){ | 244 | if(act.zh_num){ |
245 | - var be1= parseInt((act.zh_num-act.zh_buy_num)/ act.zhbuyqty)-1; | 245 | + var be1= parseInt(act.zh_num-act.zh_buy_num)-1; |
246 | if(be1<be) be=be1; | 246 | if(be1<be) be=be1; |
247 | } | 247 | } |
248 | 248 |