Browse Source

首付款不能大于合同额问题解决

dev01 2 years ago
parent
commit
148aace701

+ 4 - 4
js/component/manageCenter/order/orderNew/addService.jsx

@@ -3657,7 +3657,7 @@ const NewService = Form.create()(
         message.warning("首付款金额不能为空!");
         return false;
       }
-      if (this.state.totalAmount < this.state.firstAmount) {
+      if (Number(this.state.totalAmount) < Number(this.state.firstAmount)) {
         message.warning("首付款不能大于合同额!");
         return;
       }
@@ -3666,7 +3666,7 @@ const NewService = Form.create()(
         this.state.typeChange == 1 ||
         this.state.typeChange == 3
       ) {
-        if (this.state.settlementAmount < this.state.changeAmount) {
+        if (Number(this.state.settlementAmount) < Number(this.state.changeAmount)) {
           message.warning("退款金额大于已收款金额");
           return;
         }
@@ -4333,7 +4333,7 @@ const NewService = Form.create()(
         message.warning("首付款金额不能为空!");
         return false;
       }
-      if (this.state.totalAmount < this.state.firstAmount) {
+      if (Number(this.state.totalAmount) < Number(this.state.firstAmount)) {
         message.warning("首付款不能大于合同额!");
         return;
       }
@@ -4342,7 +4342,7 @@ const NewService = Form.create()(
         this.state.typeChange == 1 ||
         this.state.typeChange == 3
       ) {
-        if (this.state.settlementAmount < this.state.changeAmount) {
+        if (Number(this.state.settlementAmount) < Number(this.state.changeAmount)) {
           message.warning("退款金额大于已收款金额");
           return;
         }

+ 2 - 2
js/component/manageCenter/order/orderNew/changeComponent/changeApply.js

@@ -986,7 +986,7 @@ class ChangeApply extends Component {
       message.warning("首付款金额不能为空!");
       return false;
     }
-    if (this.state.data.totalAmount < this.state.data.firstAmount) {
+    if (Number(this.state.data.totalAmount) < Number(this.state.data.firstAmount)) {
       message.warning("首付款不能大于合同额!");
       return;
     }
@@ -1001,7 +1001,7 @@ class ChangeApply extends Component {
       this.state.data.type == 1 ||
       this.state.data.type == 3
     ) {
-      if (this.state.data.settlementAmount < this.state.data.changeAmount) {
+      if (Number(this.state.data.settlementAmount) < Number(this.state.data.changeAmount)) {
         message.warning("退款金额大于已收款金额");
         return;
       }