huang_an 2 ani în urmă
părinte
comite
b9a9813fea

+ 9 - 0
src/api/warehouseManagement/outin.js

@@ -84,5 +84,14 @@ export default {
     if (res.data.code == 0) {
       return res.data.data;
     }
+  },
+  //库存台账-基本信息
+  getBasicInformation: async (categoryId) => {
+    const res = await request.get(
+      `/wms/outin/getBasicInformation/${categoryId}`
+    );
+    if (res.data.code == 0) {
+      return res.data.data;
+    }
   }
 };

+ 4 - 2
src/views/warehouseManagement/stockLedger/batchDetails.vue

@@ -64,6 +64,7 @@
     ledgerdetailPage,
     ledgerPage
   } from '@/api/classifyManage/itemInformation';
+  import outin from '@/api/warehouseManagement/outin';
   export default {
     components: {
       // PageHeader,
@@ -119,11 +120,12 @@
     },
     methods: {
       async getDetailInfo(row) {
-        const res = await getDetails(row.assetId);
+        console.log('===', row);
+        const res = await outin.getBasicInformation(row.id);
         this.$nextTick(() => {
           console.log(res);
           this.$refs.baseInfoRef.getDetailInfoAugr(res.category);
-          this.$refs.warehouseConfigRef.getDetailInfoAugr(res.categoryWms);
+          // this.$refs.warehouseConfigRef.getDetailInfoAugr(res.categoryWms);
         });
         const rep = await ledgerdetailPage({
           pageNum: 1,

+ 29 - 23
src/views/warehouseManagement/stockLedger/components/item-list.vue

@@ -1,7 +1,8 @@
 <template>
   <div>
     <!-- 数据表格 -->
-    <item-search @search="reload" @handledime="handledime"> </item-search>
+    <item-search @search="reload" ref="refSeavch" @handledime="handledime">
+    </item-search>
     <ele-pro-table
       ref="table"
       :initLoad="false"
@@ -42,6 +43,8 @@
     getWarehouseList
   } from '@/api/classifyManage/itemInformation';
 
+  import ouint from '@/api/warehouseManagement/outin';
+
   export default {
     components: { ItemSearch },
     props: {
@@ -57,7 +60,7 @@
     data() {
       return {
         searchForm: {
-          dimension: 2
+          dimension: 1
         },
         isShow: false
       };
@@ -77,12 +80,12 @@
           },
 
           {
-            prop: 'assetCode',
+            prop: 'code',
             label: '编码',
             showOverflowTooltip: true
           },
           {
-            prop: 'assetName',
+            prop: 'name',
             label: '名称',
             showOverflowTooltip: true
           },
@@ -97,36 +100,36 @@
             showOverflowTooltip: true
           },
           {
-            prop: 'realInventoryNum',
+            prop: 'availableCountBase',
             label: '实时库存',
             sortable: 'custom',
             showOverflowTooltip: true
           },
           {
-            prop: 'measurementUnit',
+            prop: 'measuringUnit',
             label: '计量单位',
             align: 'center'
           },
           {
-            prop: '',
+            prop: 'weightUnit',
             label: '重量单位',
             showOverflowTooltip: true
           },
           {
-            prop: 'minPackUnit',
+            prop: 'minUnit',
             label: '包装单位',
             showOverflowTooltip: true
           },
-          {
-            prop: '',
-            label: '安全库存',
-            showOverflowTooltip: true
-          },
-          {
-            prop: '',
-            label: '质保期',
-            showOverflowTooltip: true
-          },
+          // {
+          //   prop: '',
+          //   label: '安全库存',
+          //   showOverflowTooltip: true
+          // },
+          // {
+          //   prop: '',
+          //   label: '质保期',
+          //   showOverflowTooltip: true
+          // },
           {
             columnKey: 'action',
             label: '操作',
@@ -138,7 +141,7 @@
         ];
         if (this.isShow) {
           obj.splice(1, 0, {
-            prop: 'batchNum',
+            prop: 'batchNo',
             label: '批次号',
             showOverflowTooltip: true
           });
@@ -152,10 +155,13 @@
       },
       /* 表格数据源 */
       datasource({ page, limit, where }) {
-        return pageeLedgerMain({
+        console.log();
+        const dimension = this.$refs.refSeavch.dimension;
+        return ouint.getRealTimeInventory({
           ...where,
           pageNum: page,
-          size: limit
+          size: limit,
+          dimension: dimension
         });
       },
       /* 刷新表格 */
@@ -180,7 +186,7 @@
         });
 
         const url =
-          this.searchForm.dimension === 1
+          this.$refs.refSeavch.dimension == 1
             ? '/warehouseManagement/stockLedger/allBatchDetails'
             : '/warehouseManagement/stockLedger/batchDetails';
 
@@ -188,7 +194,7 @@
           path: url,
           query: {
             key,
-            dimension: this.searchForm.dimension,
+            dimension: this.$refs.refSeavch.dimension,
             id: row.id,
             assetId: row.assetId
           }

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

@@ -96,7 +96,7 @@
         // 表单数据
         params: { ...defaultParams },
         warehouseList: [],
-        dimension: ''
+        dimension: '1'
       };
     },
     computed: {