ysy 1 yıl önce
ebeveyn
işleme
9db94557c3

+ 31 - 8
src/views/produce/components/feeding/components/productsBom.vue

@@ -1,6 +1,7 @@
 
 
 <template>
 <template>
-    <div v-if="productsObj.name != 'undefined' && productsObj.feedQuantity != 'undefined'">
+<div>
+  <!-- <div v-if="productsObj && productsObj.name != 'undefined' && productsObj.feedQuantity != 'undefined'">
         <div class="title_box rx-bc mt6">
         <div class="title_box rx-bc mt6">
             <div class="name">在制品 </div>
             <div class="name">在制品 </div>
 
 
@@ -53,16 +54,21 @@
         </div>
         </div>
       </div>
       </div>
     </div>
     </div>
-    </div>
+    </div> -->
+
+  {{ productsObj }}
+  33
+  </div>
+
 </template>
 </template>
 
 
 
 
 <script>
 <script>
 export default {
 export default {
     props: {
     props: {
-        productsObj: {
-            type: Object,
-            default: () => { }
+      product: {
+          type: Object,
+          default: () => { }
         },
         },
 
 
         itemObj: {
         itemObj: {
@@ -71,11 +77,28 @@ export default {
         }
         }
 
 
     },
     },
+
+    watch: {
+      product: {
+        immediate: true,
+        handler(newVal) {
+          console.log(newVal)
+          this.productsObj = newVal
+          this.$forceUpdate()
+        },
+        deep: true
+        
+    },
+
+    created() {
+      console.log()
+    },
+
     methods: {
     methods: {
         maxFeedQuantity() {
         maxFeedQuantity() {
-            if (this.productsObj.feedQuantity > this.itemObj.formingNum) {
-                this.$set(this.productsObj, 'feedQuantity', this.itemObj.formingNum)
-            }
+            // if (this.productsObj.feedQuantity > this.itemObj.formingNum) {
+            //     this.$set(this.productsObj, 'feedQuantity', this.itemObj.formingNum)
+            // }
         }
         }
     }
     }
 
 

+ 10 - 6
src/views/produce/components/feeding/index.vue

@@ -49,10 +49,11 @@
           :list="item.equipmentList"
           :list="item.equipmentList"
         ></deviceBom>
         ></deviceBom>
 
 
+
         <productsBom
         <productsBom
           v-if="item.product != null && item.product != '{}'"
           v-if="item.product != null && item.product != '{}'"
           :itemObj="item"
           :itemObj="item"
-          :productsObj="item.product"
+          :product="item.product"
         >
         >
         </productsBom>
         </productsBom>
 
 
@@ -128,6 +129,7 @@
   import aridRegion from './components/aridRegion.vue';
   import aridRegion from './components/aridRegion.vue';
   import palletBom from './components/palletBom.vue';
   import palletBom from './components/palletBom.vue';
   import revolvingDiskBom from './components/revolvingDiskBom.vue';
   import revolvingDiskBom from './components/revolvingDiskBom.vue';
+  import { deepClone } from '@/utils';
   export default {
   export default {
     name: 'feeding',
     name: 'feeding',
     components: {
     components: {
@@ -185,7 +187,8 @@
         };
         };
         workorderList(param)
         workorderList(param)
           .then((res) => {
           .then((res) => {
-            this.List = res.map((m) => {
+            let arr = [];
+            arr = res.map((m) => {
               m.workOrderId = m.id;
               m.workOrderId = m.id;
               m.paramDetailList = [];
               m.paramDetailList = [];
 
 
@@ -223,7 +226,9 @@
               }
               }
 
 
               // 处理字段
               // 处理字段
-              m.quality == '' ? (m.quality = {}) : '';
+              if (m.quality == '') {
+                m.product = '{}';
+              }
 
 
               if (!Object.prototype.hasOwnProperty.call(m, 'product')) {
               if (!Object.prototype.hasOwnProperty.call(m, 'product')) {
                 m.product = '{}';
                 m.product = '{}';
@@ -238,6 +243,7 @@
                 ...m
                 ...m
               };
               };
             });
             });
+            this.List = deepClone(arr);
           })
           })
           .finally(() => {
           .finally(() => {
             this.getCacheFn();
             this.getCacheFn();
@@ -461,11 +467,10 @@
           width: 80px !important;
           width: 80px !important;
           font-size: 12px;
           font-size: 12px;
         }
         }
-        .lable100{
+        .lable100 {
           width: 100px !important;
           width: 100px !important;
         }
         }
 
 
-
         .ww60 {
         .ww60 {
           width: 60px;
           width: 60px;
         }
         }
@@ -520,7 +525,6 @@
         width: 40%;
         width: 40%;
       }
       }
 
 
-
       .ww30 {
       .ww30 {
         width: 30%;
         width: 30%;
       }
       }

+ 5 - 2
src/views/produce/components/jobBooking/components/jobBom.vue

@@ -216,11 +216,14 @@
       },
       },
 
 
       handleClose() {
       handleClose() {
-        this.visible = true;
+        this.visible = false;
       },
       },
 
 
       warehouseSave() {
       warehouseSave() {
-        console.log(this.form);
+        this.$set(this.item.notFormedList[0], 'warehouseId', this.form.warehouseId || null)
+
+        this.handleClose()
+        this.$forceUpdate()
       },
       },
 
 
       handleView(name) {
       handleView(name) {

+ 4 - 0
src/views/produce/components/jobBooking/index.vue

@@ -39,6 +39,8 @@
         </div>
         </div>
 
 
         <workOrderBom :item="item"></workOrderBom>
         <workOrderBom :item="item"></workOrderBom>
+        <paramBom v-if='item.paramDetailList.length != 0' :list='item.paramDetailList'></paramBom>
+
         <jobBom :item="item" :notFormed="item.notFormedList" :warehouseList="warehouseList"></jobBom>
         <jobBom :item="item" :notFormed="item.notFormedList" :warehouseList="warehouseList"></jobBom>
       </div>
       </div>
     </div>
     </div>
@@ -50,10 +52,12 @@
   import { getWarehouseList } from '@/api/produce/index'
   import { getWarehouseList } from '@/api/produce/index'
 
 
   import workOrderBom from '../feeding/components/workOrderBom.vue';
   import workOrderBom from '../feeding/components/workOrderBom.vue';
+  import paramBom from '../feeding/components/paramBom.vue';
   import jobBom from './components/jobBom.vue';
   import jobBom from './components/jobBom.vue';
   export default {
   export default {
     components: {
     components: {
       workOrderBom,
       workOrderBom,
+      paramBom,
       jobBom
       jobBom
     },
     },
     props: {
     props: {

+ 1 - 6
src/views/produce/components/produceOrder.vue

@@ -74,12 +74,7 @@
             align: 'center'
             align: 'center'
           },
           },
 
 
-          {
-            prop: 'produceRoutingName',
-            label: '工艺路线',
-            align: 'center'
-          },
-
+      
           {
           {
             prop: 'productCode',
             prop: 'productCode',
             label: '产品编码',
             label: '产品编码',

+ 1 - 13
src/views/produce/components/productionResource/processRoute.vue

@@ -78,19 +78,7 @@
               align: 'center'
               align: 'center'
             },
             },
   
   
-            {
-              prop: 'approvalUserName',
-              label: '审核人',
-              align: 'center'
-            },
-  
-            {
-              prop: 'createTime',
-              label: '创建时间',
-              align: 'center',
-              showOverflowTooltip: true,
-              minWidth: 110
-            },
+       
             {
             {
               slot: 'approvalStatus',
               slot: 'approvalStatus',
               label: '状态',
               label: '状态',