Przeglądaj źródła

rever: 还原产品明细

wuzh 16 godzin temu
rodzic
commit
7c8955fe58
1 zmienionych plików z 47 dodań i 32 usunięć
  1. 47 32
      src/views/material/product/detail.vue

+ 47 - 32
src/views/material/product/detail.vue

@@ -677,7 +677,7 @@
   import { addMaterial } from '@/api/material/list.js';
   import { deepClone } from '@/utils/index';
   import { finishPageTab, reloadPageTab } from '@/utils/page-tab-util';
-  // import { produceTypeList } from '@/enum/dict.js';
+  import { produceTypeList } from '@/enum/dict.js';
   import { copyObj } from '@/utils/util';
   import { parameterGetByCode } from '@/api/system/dictionary/index.js';
   import GetCodeDialog from '@/components/addDoc/getCode.vue';
@@ -769,7 +769,7 @@
         isReadOnly: false,
         isShow: true,
         industryAttribute: '',
-        produceTypeList:[],
+        produceTypeList,
         packagingSpecificationList: [],
         loading: false,
         productImgs: [],
@@ -842,7 +842,24 @@
             needProductSequence: 0
           }
         },
-        lbjtList: [],
+        lbjtList: [
+          {
+            label: '自制件',
+            value: 1
+          },
+          {
+            label: '采购件',
+            value: 2
+          },
+          {
+            label: '外协件',
+            value: 3
+          },
+          {
+            label: '受托件',
+            value: 4
+          }
+        ],
         attributeList: [],
         remarkform: {
           remarkAttach: [],
@@ -1172,8 +1189,6 @@
       this.getAttributeList('inventory_type');
 
       this.getDictList('zeroPartPros');
-      this.getLbjtListList('categoryComponentAttribute');
-      this.getProduceTypeList('categoryProduceTypeList');
     },
     mounted() {
       if (this.clientEnvironmentId == 4) {
@@ -1620,33 +1635,33 @@
         }
       },
       // 生产类型字典
-      async getProduceTypeList(code) {
-        let { data: res } = await getByCode(code);
-        console.log('res----', res);
-
-        this.produceTypeList = res.map((item) => {
-          let values = Object.keys(item);
-          return {
-            value: values[0],
-            label: item[values[0]]
-          };
-        });
-        console.log('produceTypeList',this.produceTypeList);
-      },
-      // 属性类型字典
-      async getLbjtListList(code) {
-        let { data: res } = await getByCode(code);
-        console.log('res----', res);
-
-        this.lbjtList = res.map((item) => {
-          let values = Object.keys(item);
-          return {
-            value: Number(values[0]),
-            label: item[values[0]]
-          };
-        });
-        console.log('lbjtList',this.lbjtList);
-      },
+      // async getProduceTypeList(code) {
+      //   let { data: res } = await getByCode(code);
+      //   console.log('res----', res);
+
+      //   this.produceTypeList = res.map((item) => {
+      //     let values = Object.keys(item);
+      //     return {
+      //       value: values[0],
+      //       label: item[values[0]]
+      //     };
+      //   });
+      //   console.log('produceTypeList',this.produceTypeList);
+      // },
+      // // 属性类型字典
+      // async getLbjtListList(code) {
+      //   let { data: res } = await getByCode(code);
+      //   console.log('res----', res);
+
+      //   this.lbjtList = res.map((item) => {
+      //     let values = Object.keys(item);
+      //     return {
+      //       value: Number(values[0]),
+      //       label: item[values[0]]
+      //     };
+      //   });
+      //   console.log('lbjtList',this.lbjtList);
+      // },
       async getDictList(code) {
         let { data: res } = await getByCode(code);