From ad8ef21ff66a8c68a4678f405f20d991bd059e54 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=A0=82=E7=B3=96?= Date: Thu, 27 Nov 2025 15:43:27 +0800 Subject: [PATCH] =?UTF-8?q?fix(wms):=20=E4=BF=AE=E5=A4=8D=E9=92=A2?= =?UTF-8?q?=E5=8D=B7=E6=93=8D=E4=BD=9C=E4=B8=AD=E7=89=A9=E6=96=99=E7=B1=BB?= =?UTF-8?q?=E5=9E=8B=E5=92=8CID=E7=9A=84=E5=90=8C=E6=AD=A5=E9=97=AE?= =?UTF-8?q?=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 在split.vue中确保子卷继承母卷的itemType、itemId和materialType - 在typing.vue中根据materialType自动设置itemType - 在actflow.vue中使用coil-selector组件替换手动选择钢卷逻辑 --- klp-ui/src/views/wms/coil/actflow.vue | 14 ++------------ klp-ui/src/views/wms/coil/split.vue | 11 +++++++++++ klp-ui/src/views/wms/coil/typing.vue | 3 ++- 3 files changed, 15 insertions(+), 13 deletions(-) diff --git a/klp-ui/src/views/wms/coil/actflow.vue b/klp-ui/src/views/wms/coil/actflow.vue index 8fd07548..d0296df1 100644 --- a/klp-ui/src/views/wms/coil/actflow.vue +++ b/klp-ui/src/views/wms/coil/actflow.vue @@ -194,12 +194,7 @@ - - 选择钢卷 - - - {{ form.currentCoilNo }} - +
@@ -262,12 +257,6 @@ 取 消
- - - @@ -284,6 +273,7 @@ import { } from '@/api/wms/pendingAction'; import CoilSelector from '@/components/CoilSelector'; + export default { name: 'CoilActflow', dicts: ['action_type'], diff --git a/klp-ui/src/views/wms/coil/split.vue b/klp-ui/src/views/wms/coil/split.vue index e30807ba..23d20e88 100644 --- a/klp-ui/src/views/wms/coil/split.vue +++ b/klp-ui/src/views/wms/coil/split.vue @@ -662,6 +662,17 @@ export default { } // 不复制 itemType 和 itemId,让它们由 materialType 自动决定 + if (item.itemType) { + item.itemType = this.motherCoil.itemType; + } + + if (item.itemId) { + item.itemId = this.motherCoil.itemId; + } + + if (item.materialType) { + item.materialType = this.motherCoil.materialType; + } }); // 不再预加载物品列表,改为实时搜索 diff --git a/klp-ui/src/views/wms/coil/typing.vue b/klp-ui/src/views/wms/coil/typing.vue index d6d8a743..967b0818 100644 --- a/klp-ui/src/views/wms/coil/typing.vue +++ b/klp-ui/src/views/wms/coil/typing.vue @@ -587,12 +587,13 @@ export default { // 复制当前信息到更新表单 copyFromCurrent() { + const itemType = this.currentInfo.materialType === '原料' ? 'raw_material' : 'product'; this.updateForm = { currentCoilNo: this.currentInfo.currentCoilNo, team: this.currentInfo.team, materialType: this.currentInfo.materialType, // 不复制 itemType 和 itemId,让它们由 materialType 自动决定 - itemType: null, + itemType, itemId: null, grossWeight: parseFloat(this.currentInfo.grossWeight) || null, netWeight: parseFloat(this.currentInfo.netWeight) || null,