Bladeren bron

Finish Hotfix-mo-179

莫绍宝 3 jaren geleden
bovenliggende
commit
8480d25096
2 gewijzigde bestanden met toevoegingen van 36 en 8 verwijderingen
  1. 19 5
      src/views/supply/deliver/sum_list.vue
  2. 17 3
      src/views/supply/engin/engin_list.vue

+ 19 - 5
src/views/supply/deliver/sum_list.vue

@@ -217,12 +217,12 @@
                 {{ scope.row.payRebateAmount | numToFixed }}
               </template>
             </el-table-column>
-            <el-table-column align="right" label="发货折扣金额" prop="discAmount" min-width="110" show-overflow-tooltip>
+            <el-table-column align="right" label="发货折扣金额" prop="totalDiscAmount" min-width="110" show-overflow-tooltip>
               <template slot-scope="scope">
                 {{ scope.row.totalDiscAmount | numToFixed }}
               </template>
             </el-table-column>
-            <el-table-column align="right" label="折扣额合计" prop="totalDiscAmount" min-width="100" show-overflow-tooltip>
+            <el-table-column align="right" label="折扣额合计" prop="compute_zkeAmount" min-width="100" show-overflow-tooltip>
               <template slot-scope="scope">
                 {{ (scope.row.totalDiscAmount + scope.row.payRebateAmount) | numToFixed }}
               </template>
@@ -233,12 +233,12 @@
                 {{ scope.row.singlePayPrice | numToFixed }}
               </template>
             </el-table-column>
-            <el-table-column align="right" label="含税总额" prop="singlePayPrice" min-width="100" show-overflow-tooltip>
+            <el-table-column align="right" label="含税总额" prop="payAmount" min-width="100" show-overflow-tooltip>
               <template slot-scope="scope">
                 {{ scope.row.payAmount | numToFixed }}
               </template>
             </el-table-column>
-            <el-table-column align="right" label="未出库数量" prop="singlePayPrice" min-width="100" show-overflow-tooltip>
+            <el-table-column align="right" label="未出库数量" prop="" min-width="100" show-overflow-tooltip>
               <template slot-scope="scope">
                 {{ comRefundableQty(scope.row.type, scope.row.salesExamineStatus, scope.row) }}
               </template>
@@ -493,6 +493,20 @@ export default {
     }
   },
 
+  watch: {
+    dataList: {
+      handler(newValue, oldValue) {
+        if(newValue && newValue.length) {
+          newValue.forEach((item, index) => {
+            this.dataList[index].compute_zkeAmount = item.totalDiscAmount + item.payRebateAmount;
+          })
+        }
+      },
+      immediate: true,
+      deep: true
+    }
+  },
+
   created() {
     this.getSalesmanList();
     this.getCategoryList();
@@ -592,7 +606,7 @@ export default {
         res.data.records.forEach(item => {
           item.notOutNumber = item.salesStatus ? 0 : item.refundableQty;
           item.sums1 = ['refundableQty'];
-          item.sums2 = ['payAmount', 'payRebateAmount', 'discAmount', 'totalDiscAmount'];
+          item.sums2 = ['payAmount', 'payRebateAmount', 'discAmount', 'totalDiscAmount', 'singlePayPrice', 'compute_zkeAmount'];
         })
         this.dataList = res.data.records;
         this.listTotal = res.data.total;

+ 17 - 3
src/views/supply/engin/engin_list.vue

@@ -185,7 +185,7 @@
               </template>
             </el-table-column>
             <el-table-column align="right" label="已订数量" prop="hasOrderQty" min-width="100" show-overflow-tooltip></el-table-column>
-            <el-table-column align="right" label="可订数量" min-width="100" show-overflow-tooltip>
+            <el-table-column align="right" label="可订数量" prop="compute_kdQty" min-width="100" show-overflow-tooltip>
               <template slot-scope="scope">
                 {{ computeAllowQty(scope.row.qty, scope.row.hasOrderQty)}}
               </template>
@@ -364,6 +364,20 @@ export default {
     },
   },
 
+  watch: {
+    dataList: {
+      handler(newValue, oldValue) {
+        if(newValue && newValue.length) {
+          newValue.forEach((item, index) => {
+            this.dataList[index].compute_kdQty = this.computeAllowQty(item.qty, item.hasOrderQty);
+          })
+        }
+      },
+      immediate: true,
+      deep: true
+    }
+  },
+
   beforeCreate() {
     that = this;
   },
@@ -411,8 +425,8 @@ export default {
       };
       getEnginList(params).then((res) => {
         res.data.records.forEach(item => {
-          item.sums1 = ['qty'];
-          item.sums2 = ['totalAmount'];
+          item.sums1 = ['qty', 'hasOrderQty', 'compute_kdQty'];
+          item.sums2 = ['totalAmount', 'price'];
         })
         this.dataList = res.data.records;
         this.listTotal = res.data.total;