From 6ec5d3967b97b6cab23f96ca9d7e0f1fb91441f2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=83=AD=E9=A3=9E?= Date: Thu, 22 May 2025 15:02:40 +0800 Subject: [PATCH] =?UTF-8?q?fix:=E4=BF=AE=E6=94=B9=E8=B4=A7=E4=BD=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/Query/StockQuery/UnDoInfo/index.vue | 33 +++++++++++++++---- src/views/stockIn/AllocateStockIn/index.vue | 19 +++++++++-- src/views/stockIn/StockInByCharge/index.vue | 31 +++++++++++++++-- src/views/stockOut/shipRequestByTC/index.vue | 19 +++++++++-- .../stockOut/shipRequestReserve/index.vue | 17 ++++++++-- 5 files changed, 104 insertions(+), 15 deletions(-) diff --git a/src/views/Query/StockQuery/UnDoInfo/index.vue b/src/views/Query/StockQuery/UnDoInfo/index.vue index 7345153..d67d7d6 100644 --- a/src/views/Query/StockQuery/UnDoInfo/index.vue +++ b/src/views/Query/StockQuery/UnDoInfo/index.vue @@ -9,7 +9,7 @@ - + @@ -34,7 +34,6 @@
搜索 - 冲销
@@ -85,7 +84,17 @@
- + +
+ + + +
+
+ + 冲销 +
+
@@ -110,6 +119,7 @@ const { proxy }: any = getCurrentInstance(); const queryFormRef = ref(ElForm); const state = reactive({ + commitDate: "", ERPFACTORY:'', queryParams: { UNDOID: '', @@ -120,7 +130,8 @@ const state = reactive({ TypeList: [ { value: '', label: '全部' }, { value: 'A', label: '入库' }, - { value: 'B', label: '出库' } + { value: 'B', label: '出库' }, + { value: '调拨出库', label: '调拨出库' } ], page: { pageNum: 1, @@ -146,6 +157,13 @@ const state = reactive({ const { loading, list, column, queryParams, page, page_d, loading_d, list_d, column_d, active_row } = toRefs(state) onMounted(() => { + var newDate = new Date(); + var year = newDate.getFullYear(); + var moth = newDate.getMonth() + 1; + if(moth < 10) moth = '0' + moth; + var day = newDate.getDate(); + if(day < 10) day = '0' + day; + state.commitDate = year + '-' + moth + '-' + day state.column = [ { header: "物料凭证", field: "UNDOID", hide: false }, { header: "单据状态", field: "FLAG", hide: false }, @@ -251,11 +269,14 @@ function sendUndoCommit() { state.button_loading = false return; } + console.log(state.active_row) undoCommit({ undoId: state.list[0]?.UNDOID, userId: localStorage.get('userId'), - flag: state.list[0]?.FLAG, - inv_TYPE : state.list[0]?.RECEIVEREQUESTTYPE, + flag: state.active_row?.FLAG, + inv_TYPE : state.active_row?.RECEIVEREQUESTTYPE || state.active_row?.SHIPREQUESTTYPE, + lastEventName: state.active_row?.LASTEVENTNAME, + commitDate:state.commitDate }).then((res: any) => { console.log(res) if (res.success) { diff --git a/src/views/stockIn/AllocateStockIn/index.vue b/src/views/stockIn/AllocateStockIn/index.vue index edda342..bb65b24 100644 --- a/src/views/stockIn/AllocateStockIn/index.vue +++ b/src/views/stockIn/AllocateStockIn/index.vue @@ -414,7 +414,7 @@ async function handleReserve() { await allocateStockInCommit(param) .then((res: any) => { if (res.code == 'UndefinedCode' || res.code == '500') { - ElMessageBox.alert(res.data.RETURNMESSAGE, '提示框', { + ElMessageBox.alert(res.message, '提示框', { confirmButtonText: 'OK' }) state.loading = false @@ -425,10 +425,25 @@ async function handleReserve() { }) state.loading = false state.Button_state = false + state.formData= { + SHIPREQUESTNAME: '', + SHIPREQUESTSTATE: '', + ERPRECEIVELOCATION: '', + ERPFACTORY:'', + ERPRECEIVEFACTORY: '', + CUSTOMERNAME: '', + ToSHIPREQUEST: '', + ToSHIPREQUESTDetail: '', + MaterialPackingList: [], + ERPRECEIVEFACTORYDESC:'', + ERPFACTORYDESC:'' + } + state.undistributed_list = []; } }) .catch((error: any) => { - // ElMessageBox.alert(error, '提示框', { + // console.log(error) + // ElMessageBox.alert(error.message, '提示框', { // confirmButtonText: 'OK' // }) state.Button_state = false diff --git a/src/views/stockIn/StockInByCharge/index.vue b/src/views/stockIn/StockInByCharge/index.vue index dbe8ac1..5644784 100644 --- a/src/views/stockIn/StockInByCharge/index.vue +++ b/src/views/stockIn/StockInByCharge/index.vue @@ -28,14 +28,25 @@ highlight-current-row row-key="id" @row-click="handle"> + + + + @@ -802,7 +813,21 @@ function getStorageSpec(value: any) { this.locatioNFilter('') }) } - +/** + * 货位卡顿处理 + * @param query + */ + function locatioNFilter(query : any) { + console.log(query) + let arr = state.AllLocationList.filter((item : any) => { + return (item.LABEL.includes(query) || item.VALUE.includes(query)) + }) + if (arr.length > 50) { + state.LocationList = arr.slice(0, 50) + } else { + state.LocationList = arr + } +} function getERPLocation(erpfactory: any) { getQueryList({ queryId: 'GetERPLocationForCreatePO', diff --git a/src/views/stockOut/shipRequestByTC/index.vue b/src/views/stockOut/shipRequestByTC/index.vue index b3c9b08..a3efdce 100644 --- a/src/views/stockOut/shipRequestByTC/index.vue +++ b/src/views/stockOut/shipRequestByTC/index.vue @@ -534,8 +534,23 @@ function handle(row: any, event: any, column: any) { state.LShipRequestDetailName = row.SHIPREQUESTDETAILNAME state.LShipType = row.SHIPREQUESTTYPE getQueryList(state.queryParams).then((res: any) => { - state.MaterialPackingList = res.data; - state.MaterialPackingList2 = res.data; + + // 判定是否是E库存,如果是批次是E库存的销售订单号,则需要单据号相同才能显示 + getQueryList({queryId:"GetPackingRow",version:"ZWP007_E"}).then((data: any) => { + console.log(data.data[0].ENUMVALUE) + if(data.data[0].ENUMVALUE == 'Y') { + state.MaterialPackingList = (res.data || []).filter((item:any) => item.SALESHIPREQUESTNAME == state.queryParams.params.SHIPREQUESTNAME || !item.SALESHIPREQUESTNAME); + state.MaterialPackingList2 = (res.data || []).filter((item:any) => item.SALESHIPREQUESTNAME == state.queryParams.params.SHIPREQUESTNAME || !item.SALESHIPREQUESTNAME); + }else { + state.MaterialPackingList = res.data; + state.MaterialPackingList2 = res.data; + } + + }).catch((err: any) => { + state.MaterialPackingList = res.data; + state.MaterialPackingList2 = res.data; + }); + }); state.RightqueryParams.queryId = 'GetPackingRow'; diff --git a/src/views/stockOut/shipRequestReserve/index.vue b/src/views/stockOut/shipRequestReserve/index.vue index 59b364b..d8019f0 100644 --- a/src/views/stockOut/shipRequestReserve/index.vue +++ b/src/views/stockOut/shipRequestReserve/index.vue @@ -566,8 +566,21 @@ function handle(row: any, event: any, column: any) { state.queryParams.params.IsCheck = state.IsCheck getQueryList(state.queryParams).then((res: any) => { - state.MaterialPackingList = res.data; - state.MaterialPackingList2 = res.data; + getQueryList({queryId:"GetPackingRow",version:"ZWP007_E"}).then((data: any) => { + console.log(data.data[0].ENUMVALUE) + if(data.data[0].ENUMVALUE == 'Y') { + state.MaterialPackingList = (res.data || []).filter((item:any) => item.SALESHIPREQUESTNAME == state.queryParams.params.SHIPREQUESTNAME || !item.SALESHIPREQUESTNAME); + state.MaterialPackingList2 = (res.data || []).filter((item:any) => item.SALESHIPREQUESTNAME == state.queryParams.params.SHIPREQUESTNAME || !item.SALESHIPREQUESTNAME); + }else { + state.MaterialPackingList = res.data; + state.MaterialPackingList2 = res.data; + } + + }).catch((err: any) => { + state.MaterialPackingList = res.data; + state.MaterialPackingList2 = res.data; + }); + }); state.RightqueryParams.queryId = 'GetPackingRow';