From 8db323d37462b5e1f4e0cf333c67f41b9826db72 Mon Sep 17 00:00:00 2001 From: Tom Date: Tue, 13 Jan 2026 15:00:41 +0800 Subject: [PATCH] =?UTF-8?q?feat(=E7=94=9F=E4=BA=A7=E7=89=A9=E6=96=99):=20?= =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E6=9F=A5=E8=AF=A2=E5=87=BA=E5=85=A5=E5=BA=93?= =?UTF-8?q?=E8=AE=B0=E5=BD=95=E5=8A=9F=E8=83=BD=E5=B9=B6=E4=BC=98=E5=8C=96?= =?UTF-8?q?=E6=93=8D=E4=BD=9C=E5=88=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 在mminventory.js中添加queryMmInventory接口方法 - 移除MmRecordInbound和MmRecordOutbound中的操作列 - 在MmInventory中将操作按钮改为下拉菜单 - 实现查看进出库记录功能 --- .../productionMaterial/mminventory.js | 13 ++++ .../productionMaterial/MmInventory.vue | 60 +++++++++++++------ .../productionMaterial/MmRecordInbound.vue | 9 ++- .../productionMaterial/MmRecordOutbound.vue | 8 +-- 4 files changed, 64 insertions(+), 26 deletions(-) diff --git a/src/api/materialManagement/productionMaterial/mminventory.js b/src/api/materialManagement/productionMaterial/mminventory.js index 62d6bb8..7ac559b 100644 --- a/src/api/materialManagement/productionMaterial/mminventory.js +++ b/src/api/materialManagement/productionMaterial/mminventory.js @@ -125,3 +125,16 @@ export async function exportMmInventory(query) { // }) await downFile('/mes/productionMaterial/MmInventory/export', { ...query }) } + +/** + * 查询出/入库记录 + */ +export async function queryMmInventory(data) { + return request({ + url: 'mes/productionMaterial/MmInventory/GetInOrOutRecord', + method: 'post', + data: data + }) +} + + diff --git a/src/views/materialManagement/productionMaterial/MmInventory.vue b/src/views/materialManagement/productionMaterial/MmInventory.vue index 9732dbf..cf06b37 100644 --- a/src/views/materialManagement/productionMaterial/MmInventory.vue +++ b/src/views/materialManagement/productionMaterial/MmInventory.vue @@ -102,7 +102,7 @@ - + @@ -541,8 +542,8 @@ - - + + @@ -561,7 +562,8 @@ import { getMaterialOption, createInboundReceipt, getLocationOption, - createOutboundReceipt + createOutboundReceipt, + queryMmInventory } from '@/api/materialManagement/productionMaterial/mminventory.js' import { listMmTransactionType } from '@/api/materialManagement/productionMaterial/mmtransactiontype.js' import { warehouseOptions } from '@/utils/warehouse.js' @@ -667,6 +669,7 @@ const opertype = ref(0) const openStorage = ref(false) const openOutStorage = ref(false) const openUpdate = ref(false) +const openRecord = ref(false) const state = reactive({ single: true, multiple: true, @@ -699,10 +702,11 @@ const state = reactive({ options: {}, transactionOptions: {}, locationOptions: [], - inOrOut: '入库' + inOrOut: '入库', + recordData: [] }) -const { form, rules, rulesOut, rulesUpdate, options, transactionOptions, locationOptions, single, multiple, inOrOut } = toRefs(state) +const { form, rules, rulesOut, rulesUpdate, options, transactionOptions, locationOptions, single, multiple, inOrOut, recordData } = toRefs(state) // 关闭dialog function cancel() { @@ -774,6 +778,28 @@ function handleUpdate(row) { }) } +// 查看进出库记录 +function handleTickets(row) { + console.log(row, '==================') + queryMmInventory({ + searchType: 1, + materialCode: row.materialCode, + locationCode: row.locationCode, + supplierCode: row.supplierCode, + batchNo: row.batchNo + }).then((res) => { + + const { code, result } = res + console.log(res, '==================') + if (code == 200) { + openRecord.value = true + title.value = '查看进出库记录' + + state.recordData = result + } + }) +} + // 添加&修改 表单提交 function submitInboundForm() { proxy.$refs['formRef'].validate((valid) => { diff --git a/src/views/materialManagement/productionMaterial/MmRecordInbound.vue b/src/views/materialManagement/productionMaterial/MmRecordInbound.vue index 68a9132..f6e9664 100644 --- a/src/views/materialManagement/productionMaterial/MmRecordInbound.vue +++ b/src/views/materialManagement/productionMaterial/MmRecordInbound.vue @@ -91,16 +91,15 @@ - - + + @click="handleUpdate(scope.row)"> - + --> diff --git a/src/views/materialManagement/productionMaterial/MmRecordOutbound.vue b/src/views/materialManagement/productionMaterial/MmRecordOutbound.vue index 3c8b394..0a959b8 100644 --- a/src/views/materialManagement/productionMaterial/MmRecordOutbound.vue +++ b/src/views/materialManagement/productionMaterial/MmRecordOutbound.vue @@ -90,15 +90,15 @@ - + + @click="handleUpdate(scope.row)"> - + -->