yijing hai 1 ano
pai
achega
8e46451e01

+ 17 - 2
src/views/warehouseManagement/components/AssetsDialog.vue

@@ -306,6 +306,9 @@ export default {
       } else if (this.dimension == 2) {
         // 批次维度
         const data = await storageApi.getBatchList(this.searchForm);
+        for (let i = 0; i < data.list.length; i++) {
+          data.list[i].outboundNum = data.list[i].measureQuantity;
+        }
         this.tableData = data.list;
         this.total = data.count;
       } else if (this.dimension == 4) {
@@ -384,12 +387,24 @@ export default {
       }
       console.log(this.selectionList);
       let data = null;
-      if (this.dimension != 1) {
+      if (this.dimension == 3) {
         data = await storageApi.getHierarchyList({
           ids: this.selectionList.map((item) => item.id).join(','),
           type: this.dimension
         });
-      } else {
+      } else if (this.dimension == 2) {
+        data = await storageApi.getHierarchyFifo({
+          type: this.dimension,
+          ids: this.selectionList.map((item) => item.id).join(','),
+          builders: this.selectionList.map((item) => {
+            return {
+              categoryId: item.categoryId,
+              num: item.outboundNum,
+              id: item.id,
+            };
+          })
+        });
+      } else if (this.dimension == 1) {
         data = await storageApi.getHierarchyFifo({
           type: this.dimension,
           builders: this.selectionList.map((item) => {

+ 1 - 1
src/views/warehouseManagement/stockManagement/add.vue

@@ -1164,7 +1164,7 @@ export default {
     },
     // 获取物品列表
     async getListItems() {
-      const res2 = await warehouseDefinition.getTreeByGroup({ type: 1 });
+      const res2 = await warehouseDefinition.getTreeByGroup({ type: 2 });
       this.goodsLists = res2;
     },
     // 打开单据来源弹窗