Commit ef7d5b26eb6f88b8b76a6c7bb6122ebef5af31f6

Authored by yvan.ni
1 parent cdddaf7a

组合购的优化

packageE/pages/cart/cart2/zh_calculate.js
... ... @@ -158,7 +158,7 @@ module.exports = {
158 158 let be = parseInt(no_in_arr.length / act.zhbuyqty);
159 159 //如果有总数控制的时候,看还能买几组
160 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 162 if(be1<be) be=be1;
163 163 }
164 164  
... ...
pages/cart/cart/zh_calculate.js
... ... @@ -242,7 +242,7 @@ module.exports = {
242 242  
243 243 //如果有总数控制的时候,看还能买几组
244 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 246 if(be1<be) be=be1;
247 247 }
248 248  
... ...