Bladeren bron

采购订单维护-新增、编辑时改变订单类型清空子表货位

002390 1 jaar geleden
bovenliggende
commit
669bd3384b

+ 7 - 0
src/views/purchase/purchase-order/add/index.vue

@@ -143,6 +143,13 @@ export default {
         this.params.warehouseName = "";
         this.params.goodsAllocation = "";
         this.params.goodsAllocationName = "";
+        this.params["puOrderItemList"] = this.params["puOrderItemList"].map(
+          (item) => ({
+            ...item,
+            goodsAllocation: "",
+            goodsAllocationName: "",
+          })
+        );
 
         if (billList.find((item) => item === nVal)) {
           this.rules.warehouseName = [

+ 7 - 0
src/views/purchase/purchase-order/edit/index.vue

@@ -547,6 +547,13 @@ export default {
         this.params.goodsAllocation = "";
         this.params.goodsAllocationName = "";
         this.rules.goodsAllocationName = null;
+        this.params["puOrderItemList"] = this.params["puOrderItemList"].map(
+          (item) => ({
+            ...item,
+            goodsAllocation: "",
+            goodsAllocationName: "",
+          })
+        );
       }
     },