Browse Source

修改bug

695593266@qq.com 6 days ago
parent
commit
dc07fb93da
2 changed files with 31 additions and 10 deletions
  1. 29 8
      src/views/productionPlan/components/factoryAdd/index.vue
  2. 2 2
      vue.config.js

+ 29 - 8
src/views/productionPlan/components/factoryAdd/index.vue

@@ -827,7 +827,8 @@
           { label: '外销计划', value: 2 },
           { label: '预制计划', value: 3 },
           { label: '改型计划', value: 4 },
-          { label: '返工返修计划', value: 5 }
+          { label: '返工返修计划', value: 5 },
+          { label: '受托计划', value: 6 }
         ],
         loading: false,
         form: {
@@ -898,7 +899,11 @@
                   callback();
                   return;
                 }
-                if (value === undefined || value === null || String(value).trim() === '') {
+                if (
+                  value === undefined ||
+                  value === null ||
+                  String(value).trim() === ''
+                ) {
                   callback(new Error('请选择销售订单号'));
                 } else {
                   callback();
@@ -1019,12 +1024,16 @@
                 v.productType = '';
               }
               if (v.productType) {
-                this.$set(productList[index], 'bomVersionList',
+                this.$set(
+                  productList[index],
+                  'bomVersionList',
                   await this.bomListVersionFn(v.productType, v.categoryId)
                 );
               }
               if (v.bomCategoryId) {
-                this.$set(productList[index], 'routingList',
+                this.$set(
+                  productList[index],
+                  'routingList',
                   await this.changeBomIdFn(v.bomCategoryId, productList[index])
                 );
               }
@@ -1034,7 +1043,9 @@
 
         const [resAll, infoAll] = await Promise.all([
           Promise.all(
-            productList.map((item) => findBomCategoryByCategoryId(item.categoryId))
+            productList.map((item) =>
+              findBomCategoryByCategoryId(item.categoryId)
+            )
           ),
           Promise.all(
             productList.map(async (item) => {
@@ -1051,8 +1062,16 @@
           const info = infoAll[index] || {};
           const colorKey = info.colorKey || '';
           const modelKey = info.modelKey || '';
-          this.$set(productList[index], 'colorList', colorKey ? colorKey.split(',') : []);
-          this.$set(productList[index], 'modelList', modelKey ? modelKey.split(',') : []);
+          this.$set(
+            productList[index],
+            'colorList',
+            colorKey ? colorKey.split(',') : []
+          );
+          this.$set(
+            productList[index],
+            'modelList',
+            modelKey ? modelKey.split(',') : []
+          );
           this.$set(
             productList[index],
             'colorKey',
@@ -1080,7 +1099,9 @@
 
           if (!item.factoriesId) {
             this.$set(productList[index], 'factoriesId', this.factoriesId);
-            this.$set(productList[index], 'factoriesName',
+            this.$set(
+              productList[index],
+              'factoriesName',
               this.factoryList?.find((f) => f.id === this.factoriesId)?.name
             );
           }

+ 2 - 2
vue.config.js

@@ -35,14 +35,14 @@ module.exports = {
         // target: 'http://192.168.1.103:18086',
         // target: 'http://192.168.1.158:18086',
         // target: 'http://192.168.158:18086',
-        // target: 'http://192.168.1.251:18086',
+        target: 'http://192.168.1.251:18086',
         // target: 'http://192.168.1.144:18086',
         // target: 'http://192.168.1.251:18186',
         // target: 'http://192.168.1.211:18086',
         // target: 'http://192.168.1.251:18186',
         // target: 'http://192.168.1.102:18086',
         // target: 'http://aiot.zoomwin.com.cn:51001/api',
-        target: 'http://192.168.1.125:18086',
+        // target: 'http://192.168.1.125:18086',
 
         // target: 'http://192.168.1.116:18086',