Răsfoiți Sursa

refactor: 移除收款支付列表的条件判断,简化逻辑

xieyong 4 zile în urmă
părinte
comite
a3cce2db4c

+ 5 - 4
src/views/saleManage/saleOrder/components/addDialogNew.vue

@@ -2145,8 +2145,9 @@
             productList: this.$refs?.inventoryTable?.getTableValue() || [],
             typedetailList: this.$refs?.typeListRef?.getTableValue() || [],
             saleTypeName: this.getDictValue('销售类型', this.form.saleType),
-            receiptPaymentList: this.form.isGenerateReceiptPlan == 0 ? [] : 
-              this.$refs?.paymentCollectionPlanRef?.getTableValue() || [],
+            // receiptPaymentList: this.form.isGenerateReceiptPlan == 0 ? [] : 
+            //   this.$refs?.paymentCollectionPlanRef?.getTableValue() || [],
+            receiptPaymentList: this.$refs?.paymentCollectionPlanRef?.getTableValue() || [],
             endSettlementDate: this.form.settlementDate?.length
               ? this.form.settlementDate[1]
               : '',
@@ -2162,7 +2163,7 @@
           }
 
           if (commitData.needProduce != 2 && commitData.needProduce != 4) {
-            if(commitData.isGenerateReceiptPlan != 0) {
+            // if(commitData.isGenerateReceiptPlan != 0) {
                 const ratioSum = commitData.receiptPaymentList.reduce(
                 (acc, cur) => acc + +cur.ratio,
                 0
@@ -2172,7 +2173,7 @@
                 this.$message.error('比例合计不能超过100%');
                 return;
               }
-            }
+            // }
             
             let is = false;
             commitData.productList.forEach((v, i) => {