From 3f69b4dfc585c4dfbc3c07a6acf5cdd838033636 Mon Sep 17 00:00:00 2001
From: liuguocan <527956374@qq.com>
Date: 星期二, 28 十一月 2023 14:45:49 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/master'

---
 admin-web/src/views/stock/ledger/ledgerQuery/index.vue |   50 ++++++++++++++++++--------------------------------
 1 files changed, 18 insertions(+), 32 deletions(-)

diff --git a/admin-web/src/views/stock/ledger/ledgerQuery/index.vue b/admin-web/src/views/stock/ledger/ledgerQuery/index.vue
index 59c1aac..5bf9cd5 100644
--- a/admin-web/src/views/stock/ledger/ledgerQuery/index.vue
+++ b/admin-web/src/views/stock/ledger/ledgerQuery/index.vue
@@ -34,6 +34,7 @@
 import { getCategorySelectTree, goodsModel } from '@/api/baseSetting/finsystenant';
 import { getDicts } from '@/api/system/dict/data';
 import * as DateFormatter from '@/utils/DateFormatter';
+import stockType from '@/utils/stockType'
 
 export default {
   name: 'index',
@@ -75,7 +76,7 @@
           placeholder: '璇疯緭鍏�',
           defaultValue: '',
           options: [],
-          cascader: [{ key: 'categoryId', queryKey: 'goodsTemplatesId' }],
+          cascader: [{ key: 'baseGoodsModelsId', queryKey: 'goodsTemplatesId' }],
           optionsConfig: {
             label: 'goodsName',
             value: 'id',
@@ -110,20 +111,20 @@
         },
         {
           type: 'text',
-          dataIndex: 'name',
+          dataIndex: 'businessFormCode',
           label: '鍗曞彿',
           placeholder: '璇疯緭鍏�',
           defaultValue: '',
         },
         {
           type: 'date-picker',
-          dataIndex: 'val1',
+          dataIndex: 'dealTimeStart',
           label: '鏃堕棿',
           defaultValue: '',
         },
         {
           type: 'date-picker',
-          dataIndex: 'val2',
+          dataIndex: 'dealTimeEnd',
           label: '鑷�',
           defaultValue: '',
         },
@@ -181,44 +182,29 @@
         },
         // 鍒椾俊鎭�
         columns: [
-          { title: '鏈烘瀯', field: 'agencyName', align: 'left' },
-          { title: '浠撳簱', field: 'warehouseName', align: 'center' },
-          { title: '鐗╁搧鍚嶇О', field: 'goodsTemplateName', align: 'center' },
-          { title: '瑙勬牸鍨嬪彿', field: 'baseGoodsModelsName', align: 'center' },
+          { title: '鏈烘瀯', field: 'agencyName', align: 'left', width: 130 },
+          { title: '浠撳簱', field: 'warehouseName', align: 'left', width: 130 },
+          { title: '鐗╁搧鍚嶇О', field: 'goodsTemplateName', align: 'left', minWidth: 130 },
+          { title: '瑙勬牸鍨嬪彿', field: 'baseGoodsModelsName', align: 'left', width: 130 },
           {
             title: '绫诲瀷',
             field: 'summary',
-            align: 'left',
+            align: 'center',
             formatter: (row) => {
-              let result = '';
-              let arr = ['閲囪喘鍏ュ簱', '璋冩嫧', '鍏朵粬鍑哄簱', '閮ㄩ棬鍒嗗彂', '鎶ュ簾鍑哄簱', '閮ㄩ棬鐗╁搧鍥為��浠撳簱', '鐗╁搧鐩樼偣'];
-              if (row.businessType == 7) {
-                if (this.thisType == 1) {
-                  result = '鐩樼泩鍏ュ簱';
-                } else {
-                  result = '鐩樹簭鍑哄簱';
-                }
-              }else if(this.businessType == 2) {
-                if (this.thisType == 1) {
-                  result = '璋冩嫧鍏ュ簱';
-                } else {
-                  result = '璋冩嫧鍑哄簱';
-                }
-              }else {
-                result = arr[row.businessType - 1];
-              }
+              let result = stockType(row)
               return { value: result };
             },
           },
-          { title: '鍗曞彿', field: 'businessFormCode', align: 'left' },
-          { title: '鏁伴噺', field: 'thisCount', align: 'left' },
-          { title: '鎿嶄綔鍓嶆暟閲�', field: 'initialCount', align: 'left' },
-          { title: '鎿嶄綔鍚庢暟閲�', field: 'endCount', align: 'left' },
-          { title: '鍦ㄩ��', field: 'zaiTuCount', align: 'left' },
+          { title: '鍗曞彿', field: 'businessFormCode', align: 'center', width: 130 },
+          { title: '鏁伴噺', field: 'thisCount', align: 'center', width: 100 },
+          { title: '鎿嶄綔鍓嶆暟閲�', field: 'initialCount', align: 'center', width: 100 },
+          { title: '鎿嶄綔鍚庢暟閲�', field: 'endCount', align: 'center', width: 100 },
+          { title: '鍦ㄩ��', field: 'zaiTuCount', align: 'center', width: 100 },
           {
             title: '鎿嶄綔鏃堕棿',
             field: 'dealTime',
-            align: 'left',
+            align: 'center',
+            width: 160,
             formatter: (row) => {
               return { value: DateFormatter.LongToDateTime(row.dealTime) };
             },

--
Gitblit v1.9.1