refactor: 清理MES端本地product_type冗余代码,对齐WMS主数据架构

1.  移除MES端本地product_type实体、schema及相关CRUD代码,改为通过WMS内部API代理获取物料主数据
2.  更新物料管理粒度逻辑,新增"其他"类型(3)支持,同步更新入库校验规则
3.  修复前端物料选择、库存筛选等页面的类型判断逻辑,统一使用manage_mode区分管理类型
4.  清理静态资源文件冗余的样式代码,调整前端页面展示逻辑
5.  更新帮助文档,修正物料类型的说明描述
This commit is contained in:
SunYF
2026-09-22 07:41:40 +08:00
parent 12ca493c61
commit 932700ca65
84 changed files with 698 additions and 3955 deletions
+8 -2
View File
@@ -190,7 +190,7 @@ async function loadBatchOptions(code) {
// 物料选中(问题18:出库类型由物料档案自动判定,杜绝客户手选「电气件/结构件」)
function onMaterialPick(m) {
genForm.mode = m && m.manageMode === 2 ? 2 : 1
pickedType.value = m ? (m.itemType === 4 ? 'other' : (m.manageMode === 2 ? 'sn' : 'batch')) : ''
pickedType.value = m ? (m.manageMode === 3 ? 'other' : (m.manageMode === 2 ? 'sn' : 'batch')) : ''
genForm.batchNo = ''
snList.value = []
snInput.value = ''
@@ -331,7 +331,7 @@ async function submitGen() {
try {
const res = await request.post('/outbound/general', payload)
ElMessage.success(`通用出库成功:${res?.outboundNo}${res?.boxNo ? ' 箱号 ' + res.boxNo : ''}`)
Object.assign(genForm, { materialCode: '', mode: 1, batchNo: '', qty: 1, zoneCode: '', shelfNo: '', layerNo: '', positionNo: '', boxNo: '', contractNo: '', remark: '', outboundCategory: 'other', ownershipType: 'other', ownershipNo: '', targetStation: '' })
Object.assign(genForm, { outboundNo: '', materialCode: '', mode: 1, batchNo: '', qty: 1, zoneCode: '', shelfNo: '', layerNo: '', positionNo: '', boxNo: '', contractNo: '', remark: '', outboundCategory: 'other', ownershipType: 'other', ownershipNo: '', targetStation: '', inspectionNo: '' })
snInput.value = ''
snList.value = []
batchOptions.value = []
@@ -616,6 +616,9 @@ onMounted(loadDicts)
<el-table-column prop="boxNo" label="箱号" min-width="120">
<template #default="{ row }">{{ row.boxNo || '-' }}</template>
</el-table-column>
<el-table-column prop="inspectionNo" label="检测单号" min-width="160">
<template #default="{ row }">{{ row.inspectionNo || '-' }}</template>
</el-table-column>
<el-table-column prop="operator" label="操作人" width="100" align="center" />
<el-table-column label="时间" width="150" align="center">
<template #default="{ row }">{{ fmtTime(row.createdAt) }}</template>
@@ -720,6 +723,9 @@ onMounted(loadDicts)
<el-table-column prop="boxNo" label="箱号" min-width="120">
<template #default="{ row }">{{ row.boxNo || '-' }}</template>
</el-table-column>
<el-table-column prop="inspectionNo" label="检测单号" min-width="160">
<template #default="{ row }">{{ row.inspectionNo || '-' }}</template>
</el-table-column>
<el-table-column prop="operator" label="操作人" width="100" align="center" />
<el-table-column label="时间" width="150" align="center">
<template #default="{ row }">{{ fmtTime(row.createdAt) }}</template>