Kaynağa Gözat

仓库修改

huang_an 1 yıl önce
ebeveyn
işleme
3c2d964605

+ 11 - 0
src/api/warehouseManagement/index.js

@@ -195,6 +195,17 @@ export default {
     }
     return Promise.reject(new Error(res.data.message));
   },
+  // 出入库申请列表通过入库申请单查询详情(批量)
+  getApplystoragedetails: async (data) => {
+    const res = await request.post(
+      '/wms/applystoragedetail/listByAppIds',
+      data
+    );
+    if (res.data.code == 0) {
+      return res.data.data;
+    }
+    return Promise.reject(new Error(res.data.message));
+  },
   // 通过入库申请单查询详情
   getApplystorageDetailById: async (id) => {
     const res = await request.get(`/mes/applystorage/getById/${id}`);

+ 30 - 0
src/utils/dict/warehouse.js

@@ -132,3 +132,33 @@ export const wh_equStatus = [
   { code: 3, label: '盘盈', color: '#70B603' },
   { code: 4, label: '正常', color: '' }
 ];
+
+// 质检状态 0未检 1已检
+export const qualityStatus = {
+  0: '未质检',
+  1: '待检',
+  2: '已质检'
+};
+
+// 质检结果 0无 1合格 2不合格
+export const qualityResults = {
+  0: '无',
+  1: '合格',
+  2: '不合格'
+};
+
+// 质检结果下拉选项
+export const qualityResultsOptions = [
+  {
+    label: '无',
+    value: 0
+  },
+  {
+    label: '合格',
+    value: 1
+  },
+  {
+    label: '不合格',
+    value: 2
+  }
+];

+ 0 - 1
src/views/warehouseManagement/components/AssetsDialog.vue

@@ -402,7 +402,6 @@
           type: 1
         });
         this.factoryList = res.list;
-        this.handleList();
       },
       async getWarehouse() {
         const { data } = await getWarehouseList();

+ 87 - 18
src/views/warehouseManagement/components/outboundRequisitionDialog.vue

@@ -9,19 +9,21 @@
       :close-on-press-escape="false"
     >
       <div class="main">
+        <!-- @cell-click="cellClick" -->
         <ele-pro-table
           ref="table"
           :columns="columns"
           :datasource="datasource"
-          @cell-click="cellClick"
+          @select="selectChange"
+          @select-all="changeSelectAll"
           cache-key="workOrderTable"
         >
           <!-- 表头工具栏 -->
-          <template v-slot:action="{ row }">
+          <!-- <template v-slot:action="{ row }">
             <el-radio class="radio" v-model="currentId" :label="row.id"
               ><i></i
             ></el-radio>
-          </template>
+          </template> -->
           <template v-slot:totalCount="{ row }">
             {{ row.totalCount }} {{ row.measuringUnit }}
           </template>
@@ -67,6 +69,7 @@
         sceneState,
         dialogVisible: false,
         currentRow: {},
+        checkRadioData: [],
         currentId: '',
         statusOpt: [
           { label: '待处理', value: 0 },
@@ -79,11 +82,17 @@
       // 表格列配置
       columns() {
         return [
+          // {
+          //   action: 'action',
+          //   slot: 'action',
+          //   align: 'center',
+          //   label: '选择'
+          // },
           {
-            action: 'action',
-            slot: 'action',
-            align: 'center',
-            label: '选择'
+            width: 45,
+            type: 'selection',
+            columnKey: 'selection',
+            align: 'center'
           },
           {
             columnKey: 'index',
@@ -154,15 +163,65 @@
       }
     },
     methods: {
+      // 全选
+      changeSelectAll(arr) {
+        console.log('changeSelectAll---------', arr);
+        let isBoolean = arr.every(
+          (item) => arr[0].sourceType == item.sourceType
+        );
+        if (!isBoolean) {
+          this.checkRadioData = [];
+          this.$refs.table.clearSelection();
+          return this.$message.error(
+            `所选${
+              this.type == 1 ? '入库' : '出库'
+            }申请单出入库类型不一致,请重新选择`
+          );
+        }
+        if (arr.length != 0) {
+          this.checkRadioData = arr;
+        } else {
+          this.checkRadioData = [];
+        }
+      },
+      selectChange(arr, row) {
+        console.log('selectChange---------', arr);
+        let isBoolean = arr.every(
+          (item) => arr[0].sourceType == item.sourceType
+        );
+        if (!isBoolean) {
+          this.checkRadioData = [];
+          this.$refs.table.clearSelection();
+          return this.$message.error(
+            `所选${
+              this.type == 1 ? '入库' : '出库'
+            }申请单出入库类型不一致,请重新选择`
+          );
+        }
+        if (arr.length != 0) {
+          this.checkRadioData = arr;
+        } else {
+          this.checkRadioData = [];
+        }
+      },
       handleMine() {
-        if (!this.currentId) {
-          return this.$message.warning(
+        if (this.checkRadioData.length < 1) {
+          return this.$message.error(
             `请选择${this.type == 1 ? '入库' : '出库'}申请单`
           );
         }
-
+        let isBoolean = this.checkRadioData.every(
+          (item) => this.checkRadioData[0].sourceType == item.sourceType
+        );
+        if (!isBoolean) {
+          return this.$message.error(
+            `所选${
+              this.type == 1 ? '入库' : '出库'
+            }申请单出入库类型不一致,请重新选择`
+          );
+        }
         storageApi
-          .getApplystoragedetail({ applyId: this.currentId })
+          .getApplystoragedetails(this.checkRadioData.map((item) => item.id))
           .then(async (res) => {
             if (this.type == 2) {
               // 出库
@@ -177,14 +236,20 @@
               });
               if (data?.length > 0) {
                 console.log({
-                  sourceBizNo: this.currentRow.code,
+                  sourceBizNo: this.checkRadioData
+                    .map((item) => item.code)
+                    .join(','),
                   bizType: this.currentRow.sourceType,
                   assetType: res[0].rootCategoryLevelId
                 });
                 this.$emit('detailData', data, 1, {
-                  sourceBizNo: this.currentRow.code,
-                  bizType: this.currentRow.sourceType,
-                  assetType: res[0].rootCategoryLevelId
+                  sourceBizNo: this.checkRadioData
+                    .map((item) => item.code)
+                    .join(','),
+                  bizType: this.checkRadioData[0].sourceType,
+                  assetType: Array.from(
+                    new Set(res.map((item) => item.rootCategoryLevelId))
+                  ).join(',')
                 });
                 this.dialogVisible = false;
               } else {
@@ -207,9 +272,13 @@
                 };
               });
               this.$emit('detailData', data, 1, {
-                sourceBizNo: this.currentRow.code,
-                bizType: this.currentRow.sourceType,
-                assetType: res[0].rootCategoryLevelId
+                sourceBizNo: this.checkRadioData
+                  .map((item) => item.code)
+                  .join(','),
+                bizType: this.checkRadioData[0].sourceType,
+                assetType: Array.from(
+                  new Set(res.map((item) => item.rootCategoryLevelId))
+                ).join(',')
               });
               this.dialogVisible = false;
             }

+ 7 - 17
src/views/warehouseManagement/outgoingManagement/add.vue

@@ -280,14 +280,6 @@
                   {{ row.totalMoney ? row.totalMoney : 0 }}
                 </template>
               </el-table-column>
-
-              <el-table-column
-                v-if="clientEnvironmentId == 4"
-                label="采购原因"
-                align="center"
-                prop="purpose"
-                :show-overflow-tooltip="true"
-              ></el-table-column>
               <el-table-column
                 v-if="clientEnvironmentId == 4"
                 label="采购原因"
@@ -518,7 +510,11 @@
   import elTableInfiniteScroll from 'el-table-infinite-scroll';
   import warehouseDefinition from '@/api/warehouseManagement/warehouseDefinition';
   import { getTreeByGroup } from '@/api/classifyManage';
-  import { outputSceneState } from '@/utils/dict/index';
+  import {
+    outputSceneState,
+    qualityStatus,
+    qualityResults
+  } from '@/utils/dict/index';
   import outboundRequisitionDialog from '../components/outboundRequisitionDialog.vue';
   import selectTree from '@/components/selectTree';
   import AssetsDialog from '../components/AssetsDialog.vue';
@@ -536,14 +532,8 @@
       return {
         newColumns: [], // 动态表头
         goodsLists: [], // 商品列表
-        qualityStatus: {
-          0: '未质检',
-          1: '已质检'
-        }, // 质检状态 0未检 1已检
-        qualityResults: {
-          1: '合格',
-          2: '不合格'
-        }, // 质检结果 1合格 2不合格
+        qualityStatus, // 质检状态 0未检 1待检 2已检
+        qualityResults, // 质检结果 0无 1合格 2不合格
         productList: [], // 产品列表
         showPackingList: [], // 展示的包装列表
         packingList: [], // 包装列表

+ 8 - 9
src/views/warehouseManagement/outgoingManagement/details.vue

@@ -456,7 +456,12 @@
   import PageHeader from '@/components/PageHeader';
   import storageApi from '@/api/warehouseManagement';
   import { allCategoryLevel } from '@/api/classifyManage';
-  import { useDictLabel, outputSceneState } from '@/utils/dict/index';
+  import {
+    useDictLabel,
+    outputSceneState,
+    qualityStatus,
+    qualityResults
+  } from '@/utils/dict/index';
   import { mapGetters, mapActions } from 'vuex';
   export default {
     components: { PageHeader },
@@ -466,14 +471,8 @@
     data() {
       return {
         newColumns: [], // 动态表头
-        qualityStatus: {
-          0: '未质检',
-          1: '已质检'
-        }, // 质检状态 0未检 1已检
-        qualityResults: {
-          1: '合格',
-          2: '不合格'
-        }, // 质检结果 1合格 2不合格
+        qualityStatus, // 质检状态 0未检 1待检 2已检
+        qualityResults, // 质检结果 0无 1合格 2不合格
         productList: [], // 产品列表
         showPackingList: [], // 展示的包装列表
         packingList: [], // 包装列表

+ 0 - 1
src/views/warehouseManagement/outgoingManagement/index.vue

@@ -441,7 +441,6 @@
           type: 1
         });
         this.factoryList = res.list;
-        this.handleList();
       },
       openPrint(ref) {
         if (this.currentId) {

+ 9 - 1
src/views/warehouseManagement/stockLedger/components/item-search.vue

@@ -67,6 +67,12 @@
                 <el-option label="物品维度" value="1"> </el-option>
                 <el-option label="批次维度" value="2"> </el-option>
                 <el-option label="包装维度" value="3"> </el-option>
+                <el-option
+                  v-if="clientEnvironmentId == 3"
+                  label="物料维度"
+                  value="4"
+                >
+                </el-option>
               </el-select>
             </template>
           </el-form-item>
@@ -248,6 +254,9 @@
       // 是否开启响应式布局
       styleResponsive() {
         return this.$store.state.theme.styleResponsive;
+      },
+      clientEnvironmentId() {
+        return this.$store.state.user.info.clientEnvironmentId;
       }
     },
     created() {
@@ -263,7 +272,6 @@
           type: 1
         });
         this.factoryList = res.list;
-        this.handleList();
       },
       //搜索数据源
       async getArguInfo() {

+ 30 - 31
src/views/warehouseManagement/stockManagement/add.vue

@@ -264,6 +264,7 @@
                   >
                     <el-input
                       :ref="'packingQuantity' + $index"
+                      type="number"
                       @keyup.native="
                         moveFocus(
                           $event,
@@ -931,7 +932,12 @@
   import { getCode } from '@/api/codeManagement/index.js';
   import selectType from './components/selectType';
   import warehouseDefinition from '@/api/warehouseManagement/warehouseDefinition';
-  import { sceneState } from '@/utils/dict/index';
+  import {
+    sceneState,
+    qualityResultsOptions,
+    qualityResults,
+    qualityStatus
+  } from '@/utils/dict/index';
   import { getTreeByGroup } from '@/api/classifyManage';
   import outin from '@/api/warehouseManagement/outin';
   import { deepClone } from '@/utils';
@@ -976,24 +982,9 @@
             trigger: 'change'
           }
         },
-        qualityResultsOptions: [
-          {
-            label: '合格',
-            value: 1
-          },
-          {
-            label: '不合格',
-            value: 2
-          }
-        ],
-        qualityStatus: {
-          0: '未质检',
-          1: '已质检'
-        }, // 质检状态 0未检 1已检
-        qualityResults: {
-          1: '合格',
-          2: '不合格'
-        }, // 质检结果 1合格 2不合格
+        qualityResultsOptions, // 质检结果下拉选项 0无 1合格 2不合格
+        qualityStatus, // 质检状态 0未检 1已检
+        qualityResults, // 质检结果 0无 1合格 2不合格
         productList: [], // 产品列表
         packingList: [], // 包装列表
         showPackingList: [], // 包装列表(虚拟列表)
@@ -1197,17 +1188,23 @@
         if (isClear) {
           this.$set(this.productList[index], 'warehouseId', '');
           this.$set(this.productList[index], 'warehouseName', '');
-          if (row.packingQuantity < 1) {
+          if (row.packingQuantity < 0) {
             this.$set(this.productList[index], 'packingQuantity', 1);
           } else if (row.packingQuantity > 9999) {
             this.$set(this.productList[index], 'packingQuantity', 9999);
-          } else {
-            this.$set(
-              this.productList[index],
-              'packingQuantity',
-              row.packingQuantity.replace(/[^\d\.{2,}]/g, '')
-            );
           }
+          // else {
+          //   const reg = /^[0-9]+\.[0-9]+$/;
+          //   console.log(reg.test(row.packingQuantity));
+          //   if (reg.test(row.packingQuantity)) {
+          //     this.$set(this.productList[index], 'packingQuantity', '');
+          //   }
+          //   // this.$set(
+          //   //   this.productList[index],
+          //   //   'packingQuantity',
+          //   //   row.packingQuantity.replace(/[^\d\.{2,}]/g, '')
+          //   // );
+          // }
         }
         if (row.packingQuantity && row.packingUnit) {
           console.log(index);
@@ -1245,6 +1242,7 @@
       },
       async outboundRequisitionSelection(data, dimension, query) {
         console.log('data-----------', data);
+        console.log('query-----------', query);
         this.formData.sourceBizNo = query.sourceBizNo;
         this.formData.bizType = query.bizType;
         this.formData.extInfo.assetType = query.assetType.split(',');
@@ -1281,6 +1279,7 @@
               productItem.outInDetailRecordRequestList?.length > 0
                 ? true
                 : false,
+            netWeight: productItem.netWeight > 0 ? productItem.netWeight : 0,
             batchNo: batchNo, // 批次号
             warehouseIds: [productItem.warehouseId], // 仓库Id
             warehouseNames: [productItem.warehouseName], // 仓库名称
@@ -1909,13 +1908,13 @@
       materialResultCahnge(value, row) {
         // 修改包装质检结果
         let filterMaterialList = this.materialList.filter((item) => {
-          return item.parentIndex === row.parentIndex;
+          return item.parentIndex == row.parentIndex;
         });
         let packingIndex = this.packingList.findIndex((item) => {
-          return item.index === row.parentIndex;
+          return item.index == row.parentIndex;
         });
         let boolen = filterMaterialList.every((item) => {
-          return item.result === 1;
+          return item.result == 1;
         });
         this.$set(this.packingList[packingIndex], 'result', boolen ? 1 : 2);
       },
@@ -2872,13 +2871,13 @@
       changeWrapStatus(resultValue, row, type) {
         console.log(resultValue);
         switch (resultValue) {
-          case '0':
+          case 0:
             // 清空质检状态
             row.status = 0;
             break;
           default:
             // 默认已检质检状态
-            row.status = 1;
+            row.status = 2;
             break;
         }
         if (type === '包装') {

+ 35 - 40
src/views/warehouseManagement/stockManagement/add_2.vue

@@ -989,7 +989,12 @@
   import { getCode } from '@/api/codeManagement/index.js';
   import selectType from './components/selectType';
   import warehouseDefinition from '@/api/warehouseManagement/warehouseDefinition';
-  import { sceneState } from '@/utils/dict/index';
+  import {
+    sceneState,
+    qualityResultsOptions,
+    qualityResults,
+    qualityStatus
+  } from '@/utils/dict/index';
   import { getTreeByGroup } from '@/api/classifyManage';
   import outin from '@/api/warehouseManagement/outin';
   import { deepClone } from '@/utils';
@@ -1033,24 +1038,9 @@
             trigger: 'change'
           }
         },
-        qualityResultsOptions: [
-          {
-            label: '合格',
-            value: 1
-          },
-          {
-            label: '不合格',
-            value: 2
-          }
-        ],
-        qualityStatus: {
-          0: '未质检',
-          1: '已质检'
-        }, // 质检状态 0未检 1已检
-        qualityResults: {
-          1: '合格',
-          2: '不合格'
-        }, // 质检结果 1合格 2不合格
+        qualityResultsOptions, // 质检结果下拉选项 0无 1合格 2不合格
+        qualityStatus, // 质检状态 0未检 1已检
+        qualityResults, // 质检结果 0无 1合格 2不合格
         productList: [], // 产品列表
         packingList: [], // 包装列表
         showPackingList: [], // 包装列表(虚拟列表)
@@ -1870,13 +1860,13 @@
       materialResultCahnge(value, row) {
         // 修改包装质检结果
         let filterMaterialList = this.materialList.filter((item) => {
-          return item.parentIndex === row.parentIndex;
+          return item.parentIndex == row.parentIndex;
         });
         let packingIndex = this.packingList.findIndex((item) => {
-          return item.index === row.parentIndex;
+          return item.index == row.parentIndex;
         });
         let boolen = filterMaterialList.every((item) => {
-          return item.result === 1;
+          return item.result == 1;
         });
         this.$set(this.packingList[packingIndex], 'result', boolen ? 1 : 2);
       },
@@ -1931,22 +1921,27 @@
       // 包装维度最小包装单元改变——>总重量
       minPackingQuantityChange(row, value, index) {
         console.log(value);
-        if (row.measureUnit !== 'KG') {
-          if (value.replace(/^(0+)|[^\d]+/g, '') > 999999) {
-            this.$set(this.productList[index], 'minPackingQuantity', 999999);
-          } else {
-            this.$set(
-              this.productList[index],
-              'minPackingQuantity',
-              value.replace(/^(0+)|[^\d]+/g, '')
-            );
-          }
-        } else {
-          if (value < 1) {
-            this.$set(this.productList[index], 'minPackingQuantity', 1);
-          } else if (value > 999999) {
-            this.$set(this.productList[index], 'minPackingQuantity', 999999);
-          }
+        // if (row.measureUnit !== 'KG') {
+        //   if (value.replace(/^(0+)|[^\d]+/g, '') > 999999) {
+        //     this.$set(this.productList[index], 'minPackingQuantity', 999999);
+        //   } else {
+        //     this.$set(
+        //       this.productList[index],
+        //       'minPackingQuantity',
+        //       value.replace(/^(0+)|[^\d]+/g, '')
+        //     );
+        //   }
+        // } else {
+        //   if (value < 0) {
+        //     this.$set(this.productList[index], 'minPackingQuantity', 1);
+        //   } else if (value > 9999) {
+        //     this.$set(this.productList[index], 'minPackingQuantity', 9999);
+        //   }
+        // }
+        if (value < 0) {
+          this.$set(this.productList[index], 'minPackingQuantity', 1);
+        } else if (value > 9999) {
+          this.$set(this.productList[index], 'minPackingQuantity', 9999);
         }
         if (row.packingQuantity >= 0 && value >= 0) {
           this.packNum(row, row.packingQuantity, index);
@@ -2485,13 +2480,13 @@
       changeWrapStatus(resultValue, row, type) {
         console.log(resultValue);
         switch (resultValue) {
-          case '0':
+          case 0:
             // 清空质检状态
             row.status = 0;
             break;
           default:
             // 默认已检质检状态
-            row.status = 1;
+            row.status = 2;
             break;
         }
         if (type === '包装') {

+ 30 - 31
src/views/warehouseManagement/stockManagement/add_3.vue

@@ -264,6 +264,7 @@
                   >
                     <el-input
                       :ref="'packingQuantity' + $index"
+                      type="number"
                       @keyup.native="
                         moveFocus(
                           $event,
@@ -931,7 +932,12 @@
   import { getCode } from '@/api/codeManagement/index.js';
   import selectType from './components/selectType';
   import warehouseDefinition from '@/api/warehouseManagement/warehouseDefinition';
-  import { sceneState } from '@/utils/dict/index';
+  import {
+    sceneState,
+    qualityResultsOptions,
+    qualityResults,
+    qualityStatus
+  } from '@/utils/dict/index';
   import { getTreeByGroup } from '@/api/classifyManage';
   import outin from '@/api/warehouseManagement/outin';
   import { deepClone } from '@/utils';
@@ -976,24 +982,9 @@
             trigger: 'change'
           }
         },
-        qualityResultsOptions: [
-          {
-            label: '合格',
-            value: 1
-          },
-          {
-            label: '不合格',
-            value: 2
-          }
-        ],
-        qualityStatus: {
-          0: '未质检',
-          1: '已质检'
-        }, // 质检状态 0未检 1已检
-        qualityResults: {
-          1: '合格',
-          2: '不合格'
-        }, // 质检结果 1合格 2不合格
+        qualityResultsOptions, // 质检结果下拉选项 0无 1合格 2不合格
+        qualityStatus, // 质检状态 0未检 1已检
+        qualityResults, // 质检结果 0无 1合格 2不合格
         productList: [], // 产品列表
         packingList: [], // 包装列表
         showPackingList: [], // 包装列表(虚拟列表)
@@ -1197,17 +1188,23 @@
         if (isClear) {
           this.$set(this.productList[index], 'warehouseId', '');
           this.$set(this.productList[index], 'warehouseName', '');
-          if (row.packingQuantity < 1) {
+          if (row.packingQuantity < 0) {
             this.$set(this.productList[index], 'packingQuantity', 1);
           } else if (row.packingQuantity > 9999) {
             this.$set(this.productList[index], 'packingQuantity', 9999);
-          } else {
-            this.$set(
-              this.productList[index],
-              'packingQuantity',
-              row.packingQuantity.replace(/[^\d\.{2,}]/g, '')
-            );
           }
+          // else {
+          //   const reg = /^[0-9]+\.[0-9]+$/;
+          //   console.log(reg.test(row.packingQuantity));
+          //   if (reg.test(row.packingQuantity)) {
+          //     this.$set(this.productList[index], 'packingQuantity', '');
+          //   }
+          //   // this.$set(
+          //   //   this.productList[index],
+          //   //   'packingQuantity',
+          //   //   row.packingQuantity.replace(/[^\d\.{2,}]/g, '')
+          //   // );
+          // }
         }
         if (row.packingQuantity && row.packingUnit) {
           console.log(index);
@@ -1245,6 +1242,7 @@
       },
       async outboundRequisitionSelection(data, dimension, query) {
         console.log('data-----------', data);
+        console.log('query-----------', query);
         this.formData.sourceBizNo = query.sourceBizNo;
         this.formData.bizType = query.bizType;
         this.formData.extInfo.assetType = query.assetType.split(',');
@@ -1281,6 +1279,7 @@
               productItem.outInDetailRecordRequestList?.length > 0
                 ? true
                 : false,
+            netWeight: productItem.netWeight > 0 ? productItem.netWeight : 0,
             batchNo: batchNo, // 批次号
             warehouseIds: [productItem.warehouseId], // 仓库Id
             warehouseNames: [productItem.warehouseName], // 仓库名称
@@ -1909,13 +1908,13 @@
       materialResultCahnge(value, row) {
         // 修改包装质检结果
         let filterMaterialList = this.materialList.filter((item) => {
-          return item.parentIndex === row.parentIndex;
+          return item.parentIndex == row.parentIndex;
         });
         let packingIndex = this.packingList.findIndex((item) => {
-          return item.index === row.parentIndex;
+          return item.index == row.parentIndex;
         });
         let boolen = filterMaterialList.every((item) => {
-          return item.result === 1;
+          return item.result == 1;
         });
         this.$set(this.packingList[packingIndex], 'result', boolen ? 1 : 2);
       },
@@ -2872,13 +2871,13 @@
       changeWrapStatus(resultValue, row, type) {
         console.log(resultValue);
         switch (resultValue) {
-          case '0':
+          case 0:
             // 清空质检状态
             row.status = 0;
             break;
           default:
             // 默认已检质检状态
-            row.status = 1;
+            row.status = 2;
             break;
         }
         if (type === '包装') {

+ 0 - 1
src/views/warehouseManagement/stockManagement/components/selectType.vue

@@ -240,7 +240,6 @@
           type: 1
         });
         this.factoryList = res.list;
-        this.handleList();
       },
       doLayout() {
         let that = this;

+ 8 - 9
src/views/warehouseManagement/stockManagement/details.vue

@@ -532,7 +532,12 @@
   import PageHeader from '@/components/PageHeader';
   import storageApi from '@/api/warehouseManagement';
   import { allCategoryLevel } from '@/api/classifyManage';
-  import { useDictLabel, sceneState } from '@/utils/dict/index';
+  import {
+    useDictLabel,
+    sceneState,
+    qualityStatus,
+    qualityResults
+  } from '@/utils/dict/index';
   import { mapGetters, mapActions } from 'vuex';
   export default {
     components: { PageHeader, WareHouseDailog },
@@ -542,14 +547,8 @@
     data() {
       return {
         newColumns: [], // 动态表头
-        qualityStatus: {
-          0: '未质检',
-          1: '已质检'
-        }, // 质检状态 0未检 1已检
-        qualityResults: {
-          1: '合格',
-          2: '不合格'
-        }, // 质检结果 1合格 2不合格
+        qualityStatus, // 质检状态 0未检 1已检
+        qualityResults, // 质检结果 0无 1合格 2不合格
         productList: [], // 产品列表
         showPackingList: [], // 展示的包装列表
         packingList: [], // 包装列表

+ 0 - 1
src/views/warehouseManagement/stockManagement/index.vue

@@ -411,7 +411,6 @@
           type: 1
         });
         this.factoryList = res.list;
-        this.handleList();
       },
       // 单击获取id
       cellClick(row) {

+ 3 - 3
src/views/warehouseManagement/warehouseDefinition/index.vue

@@ -223,11 +223,11 @@
           >
             <template slot="header" slot-scope="scope"> 操作 </template>
             <template slot-scope="{ row, $index }">
-              <el-button type="text" @click="add(row)">修改仓库</el-button>
+              <el-button type="text" @click="add(row)">修改</el-button>
               <el-button type="text" @click="locationManage(row)"
-                >货位管理</el-button
+                >货位</el-button
               >
-              <el-button type="text" @click="details(row)">查看详情</el-button>
+              <el-button type="text" @click="details(row)">详情</el-button>
               <el-button type="text" @click="remove(row)">删除</el-button>
             </template>
           </el-table-column>