From cd8b52bdf89a4d1101f72e0ece9f4df22a3d3f7a Mon Sep 17 00:00:00 2001
From: gaoluyang <2820782392@qq.com>
Date: 星期四, 15 十月 2026 16:03:32 +0800
Subject: [PATCH] feat(mdm): 物料列表隐藏辅单位与销售价列
---
src/views/mes/pro/workorder/index.vue | 17 ++++++++++++-----
1 files changed, 12 insertions(+), 5 deletions(-)
diff --git a/src/views/mes/pro/workorder/index.vue b/src/views/mes/pro/workorder/index.vue
index 05d1c44..1547165 100644
--- a/src/views/mes/pro/workorder/index.vue
+++ b/src/views/mes/pro/workorder/index.vue
@@ -32,7 +32,8 @@
destroyOnClose: true,
});
- const archiveDetailRef = ref<InstanceType<typeof ArchiveDetail>>();
+ const archiveVisible = ref(false);
+ const archiveProductCode = ref('');
// const barcodeDetailRef = ref<InstanceType<typeof BarcodeDetail>>(); // 鏉$爜璇︽儏寮圭獥
/** 鍒锋柊琛ㄦ牸 */
@@ -67,7 +68,7 @@
/** 瀹屾垚璁㈠崟鍓嶆牎楠� */
function handleCheckFinish(row: MesProWorkOrderApi.WorkOrder) {
- if (row.productionStatus !== 2) {
+ if (row.status !== MesProWorkOrderStatusEnum.FINISHED) {
Modal.confirm({
title: '鎿嶄綔纭',
content: '璇ヨ鍗曟湭瀹屾垚锛屾槸鍚︾‘璁よ缁х画瀹屾垚锛�',
@@ -100,6 +101,12 @@
await cancelWorkOrder(row.id!);
message.success("璁㈠崟宸插彇娑�");
handleRefresh();
+ }
+
+ /** 鎵撳紑褰掓。璇︽儏 */
+ function handleArchive(row: MesProWorkOrderApi.WorkOrder) {
+ archiveProductCode.value = row.productCode || '';
+ archiveVisible.value = true;
}
/** 鏌ョ湅璁㈠崟鏉$爜 */
@@ -237,7 +244,7 @@
},
},
{
- label: $t('common.create'),
+ label: '鏂板瀛愯鍗�',
type: 'link',
auth: ['mes:pro-work-order:create'],
ifShow:
@@ -274,13 +281,13 @@
{
label: '褰掓。',
type: 'link',
- onClick: () => archiveDetailRef.value?.open(row.productCode),
+ onClick: handleArchive.bind(null, row),
},
]" />
</template>
</Grid>
<!-- <BarcodeDetail ref="barcodeDetailRef" /> -->
- <ArchiveDetail ref="archiveDetailRef" />
+ <ArchiveDetail :visible="archiveVisible" :product-code="archiveProductCode" @update:visible="archiveVisible = $event" />
</Page>
</template>
--
Gitblit v1.9.3