zhengjinyi преди 4 години
родител
ревизия
b214854697
променени са 2 файла, в които са добавени 8 реда и са изтрити 7 реда
  1. 8 5
      src/main/resources/static/js/shopping/confirm.js
  2. 0 2
      src/main/resources/static/js/user-center/account/beans.js

+ 8 - 5
src/main/resources/static/js/shopping/confirm.js

@@ -143,6 +143,7 @@ var shoppingConfirm = new Vue({
                             if( _self.userBeans >= r.data.freight*100 ){
                             if( _self.userBeans >= r.data.freight*100 ){
                                 _self.freightBeansMoney = r.data.freight;
                                 _self.freightBeansMoney = r.data.freight;
                                 _self.freightMoney = r.data.freight;
                                 _self.freightMoney = r.data.freight;
+                                console.log('freightBeansMoney',_self.freightBeansMoney);
                                 _self.isBeansShow = true;
                                 _self.isBeansShow = true;
                             }else{
                             }else{
                                 _self.isBeansShow = false;
                                 _self.isBeansShow = false;
@@ -423,11 +424,13 @@ var shoppingConfirm = new Vue({
             if(_self.balance.isFreight){
             if(_self.balance.isFreight){
                 _self.hanldUserBeans = _self.freightBeansMoney*100;
                 _self.hanldUserBeans = _self.freightBeansMoney*100;
                 if(_self.payInfo.freePostFlag == 1){
                 if(_self.payInfo.freePostFlag == 1){
-                    console.log('商品总价-------->',_self.totalPrice);
-                    console.log('邮费------------>',_self.payInfo.freight);
-                    console.log('采美豆换算金额--->',_self.freightBeansMoney);
-                    _self.payInfo.orderShouldPayFee = ((_self.totalPrice + _self.payInfo.freight)*100 - _self.freightBeansMoney*100)/100;
-                    console.log('最终支付金额---->',_self.payInfo.orderShouldPayFee)
+                    if( _self.userBeans >= _self.payInfo.freight*100 ){
+                        console.log('商品总价-------->',_self.totalPrice);
+                        console.log('邮费------------>',_self.payInfo.freight);
+                        console.log('采美豆换算金额--->',_self.freightBeansMoney);
+                        _self.payInfo.orderShouldPayFee = ((_self.totalPrice + _self.payInfo.freight)*100 - _self.freightBeansMoney*100)/100;
+                        console.log('最终支付金额---->',_self.payInfo.orderShouldPayFee)
+                    }
                 }else{
                 }else{
                     _self.payInfo.orderShouldPayFee = _self.totalPrice ;
                     _self.payInfo.orderShouldPayFee = _self.totalPrice ;
                     _self.hanldUserBeans = 0
                     _self.hanldUserBeans = 0

+ 0 - 2
src/main/resources/static/js/user-center/account/beans.js

@@ -188,7 +188,5 @@ var orderPage = new Vue({
             _self.initDate();
             _self.initDate();
             _self.GetQueryBeansListData();
             _self.GetQueryBeansListData();
         }
         }
-        $('.navLayout').find('.navList').removeClass("on").find('.con').hide().find('a').removeClass("on");
-        $('.navLayout').find('.navList').eq(0).addClass("on").find('.con').show().find('a').eq(0).addClass("on");
     }
     }
 });
 });