diff --git a/packageC/pages/luckyGo/luckyGo_cart/luckyGo_cart.js b/packageC/pages/luckyGo/luckyGo_cart/luckyGo_cart.js index bcd20f5..4376ca3 100644 --- a/packageC/pages/luckyGo/luckyGo_cart/luckyGo_cart.js +++ b/packageC/pages/luckyGo/luckyGo_cart/luckyGo_cart.js @@ -2192,11 +2192,10 @@ Page({ var txt4 = "formData.use_commission"; if(th.data.bn_use_commission){ - order_m=parseFloat(order_m)- parseFloat(th.data.bn_goods.use_commission); + order_m=(parseFloat(order_m)- parseFloat(th.data.bn_goods.use_commission)).toFixed(2); th.setData({[txt4]:th.data.bn_goods.use_commission}) } - var amoney = parseFloat(th.data.userinfo.user_money - th.data.txmon - th.data.userinfo.frozen_money); //--------------如果使用余额--------------------- if (th.data.bn_use_money == 1) { @@ -2257,7 +2256,7 @@ Page({ var txt4= "formData.use_commission"; if(th.data.bn_use_commission){ - order_m=parseFloat(order_m)- parseFloat(th.data.bn_goods.use_commission); + order_m=(parseFloat(order_m)- parseFloat(th.data.bn_goods.use_commission)).toFixed(2); th.setData({[txt4]:th.data.bn_goods.use_commission}) } @@ -2265,7 +2264,7 @@ Page({ var amoney = parseFloat(th.data.userinfo.user_money - th.data.txmon - th.data.userinfo.frozen_money); //--------------如果使用余额--------------------- if (th.data.bn_use_money == 1) { - if (amoney > order_m) { + if (amoney > parseFloat(order_m)) { order_m = parseFloat(order_m).toFixed(2); th.setData({ [txt]: order_m, [txt2]: 0, [txt3]: coupon_price, show_submit: 1 }) } else { diff --git a/packageC/pages/luckyGo/luckyGo_cart_ct/luckyGo_cart_ct.js b/packageC/pages/luckyGo/luckyGo_cart_ct/luckyGo_cart_ct.js index d43dd88..a446e4e 100644 --- a/packageC/pages/luckyGo/luckyGo_cart_ct/luckyGo_cart_ct.js +++ b/packageC/pages/luckyGo/luckyGo_cart_ct/luckyGo_cart_ct.js @@ -796,14 +796,14 @@ Page({ } if(th.data.bn_use_commission){ - order_m=parseFloat(order_m)- parseFloat(th.data.bn_goods.use_commission); + order_m=(parseFloat(order_m)- parseFloat(th.data.bn_goods.use_commission)).toFixed(2); th.setData({[txt4]:th.data.bn_goods.use_commission}) } //--------------如果使用余额--------------------- if (th.data.bn_use_money == 1 && th.data.yuer > 0) { - if (parseFloat(th.data.yuer) > total_m) { + if (parseFloat(th.data.yuer) > parseFloat(order_m)) { th.setData({ - [txt]: total_m, + [txt]: order_m, [txt2]: 0, is_show_sub:1,sub:0 }) diff --git a/packageC/pages/presell/cart/cart.js b/packageC/pages/presell/cart/cart.js index d6d4f76..4d8c024 100644 --- a/packageC/pages/presell/cart/cart.js +++ b/packageC/pages/presell/cart/cart.js @@ -2206,7 +2206,7 @@ Page({ the_price-=th.data.bn_use_commission; } - th.setData({ exp_price: exp_price, order_m:the_price, show_submit: 1, }) + th.setData({ exp_price: exp_price, order_m:the_price.toFixed(2), show_submit: 1, }) } }, diff --git a/packageC/pages/presell/cart/cart2.js b/packageC/pages/presell/cart/cart2.js index 76ad5d8..0280add 100644 --- a/packageC/pages/presell/cart/cart2.js +++ b/packageC/pages/presell/cart/cart2.js @@ -993,14 +993,14 @@ Page({ var txt4 = "formData.use_commission"; if(th.data.bn_use_commission){ - order_m=parseFloat(order_m)- parseFloat(th.data.bn_goods.use_commission); + order_m=(parseFloat(order_m)- parseFloat(th.data.bn_goods.use_commission)).toFixed(2); th.setData({[txt4]:th.data.bn_goods.use_commission}) } var amoney = parseFloat(th.data.userinfo.user_money - th.data.txmon - th.data.userinfo.frozen_money); //--------------如果使用余额--------------------- if (th.data.bn_use_money == 1) { - if (amoney > order_m) { + if (amoney > parseFloat(order_m)) { order_m = parseFloat(order_m).toFixed(2); th.setData({ [txt]: order_m, [txt2]: 0, [txt3]: coupon_price, show_submit: 1,dis_btn:0 }) } else { @@ -1119,7 +1119,7 @@ Page({ var txt4 = "formData.use_commission"; if(th.data.bn_use_commission){ - order_m=parseFloat(order_m)- parseFloat(th.data.bn_goods.use_commission); + order_m=(parseFloat(order_m)- parseFloat(th.data.bn_goods.use_commission)).toFixed(2); th.setData({[txt4]:th.data.bn_goods.use_commission}) } diff --git a/pages/cart/cart2/cart2.js b/pages/cart/cart2/cart2.js index 7e77c38..42b4f98 100644 --- a/pages/cart/cart2/cart2.js +++ b/pages/cart/cart2/cart2.js @@ -2772,7 +2772,7 @@ Page({ var txt4 = "formData.use_commission"; if(th.data.bn_use_commission){ - order_m=parseFloat(order_m)- parseFloat(th.data.bn_goods.use_commission); + order_m=(parseFloat(order_m)- parseFloat(th.data.bn_goods.use_commission)).toFixed(2); th.setData({[txt4]:th.data.bn_goods.use_commission}) } @@ -2781,7 +2781,7 @@ Page({ var amoney = parseFloat(th.data.userinfo.user_money - th.data.txmon - th.data.userinfo.frozen_money); //--------------如果使用余额--------------------- if (th.data.bn_use_money == 1) { - if (amoney > order_m) { + if (amoney > parseFloat(order_m)) { order_m = parseFloat(order_m).toFixed(2); th.setData({ [txt]: order_m, [txt2]: 0, [txt3]: coupon_price, show_submit: 1,submit:0 }) } else { @@ -2919,7 +2919,7 @@ Page({ var txt4= "formData.use_commission"; if(th.data.bn_use_commission){ - order_m=parseFloat(order_m)- parseFloat(th.data.bn_goods.use_commission); + order_m=(parseFloat(order_m)- parseFloat(th.data.bn_goods.use_commission)).toFixed(2); th.setData({[txt4]:th.data.bn_goods.use_commission}) } diff --git a/pages/cart/cart2_inte/cart2_inte.js b/pages/cart/cart2_inte/cart2_inte.js index 47556b8..82f9b89 100644 --- a/pages/cart/cart2_inte/cart2_inte.js +++ b/pages/cart/cart2_inte/cart2_inte.js @@ -704,15 +704,15 @@ Page({ var txt5 = "formData.use_commission"; if(th.data.bn_use_commission){ - order_m=parseFloat(order_m)- parseFloat(th.data.bn_goods.use_commission); + order_m=(parseFloat(order_m)- parseFloat(th.data.bn_goods.use_commission)).toFixed(2); th.setData({[txt5]:th.data.bn_goods.use_commission}) } var amoney = parseFloat(th.data.userinfo.user_money - th.data.txmon - th.data.userinfo.frozen_money); //--------------如果使用余额--------------------- if (th.data.bn_use_money == 1) { - if (amoney > order_m) { - order_m = order_m.toFixed(2); + if (amoney > parseFloat(order_m)) { + order_m = parseFloat(order_m).toFixed(2); th.setData({ [txt]: order_m, [txt2]: 0, [txt4]: all_integral, show_submit: 1,submit:0 }) } else { order_m = parseFloat(order_m - amoney); diff --git a/pages/cart/cart2_pt/cart2_pt.js b/pages/cart/cart2_pt/cart2_pt.js index 2c3a8f2..9faac8c 100644 --- a/pages/cart/cart2_pt/cart2_pt.js +++ b/pages/cart/cart2_pt/cart2_pt.js @@ -717,14 +717,14 @@ Page({ if(th.data.bn_use_commission){ - order_m=parseFloat(order_m)- parseFloat(th.data.bn_goods.use_commission); + order_m= (parseFloat(order_m)- parseFloat(th.data.bn_goods.use_commission)).toFixed(2); th.setData({[txt4]:th.data.bn_goods.use_commission}) } //--------------如果使用余额--------------------- if (th.data.bn_use_money == 1 && th.data.yuer > 0) { - if (parseFloat(th.data.yuer) > total_m) { - th.setData({[txt]: total_m, [txt2]: 0, submit: 0, show_btn: 1}) + if (parseFloat(th.data.yuer) > parseFloat(order_m)) { + th.setData({[txt]: order_m, [txt2]: 0, submit: 0, show_btn: 1}) } else { order_m = parseFloat(order_m) - parseFloat(th.data.yuer); order_m = order_m.toFixed(2); diff --git a/pages/cart/cart2_pt/cart2_pt.wxml b/pages/cart/cart2_pt/cart2_pt.wxml index 306d3aa..7d2437f 100644 --- a/pages/cart/cart2_pt/cart2_pt.wxml +++ b/pages/cart/cart2_pt/cart2_pt.wxml @@ -134,7 +134,7 @@ - 使用余额 :¥{{bn_goods.use_commission}} + 使用佣金 :¥{{bn_goods.use_commission}}