feat(wms): 新增钢卷表面处理字段及相关功能

在钢卷相关实体类、前端页面和查询逻辑中新增钢卷表面处理字段,包括:
1. 在WmsMaterialCoil、WmsMaterialCoilVo、WmsMaterialCoilBo中新增coilSurfaceTreatment字段
2. 在前端多个页面中新增钢卷表面处理的展示和编辑功能
3. 在查询逻辑中新增对钢卷表面处理的过滤条件
4. 新增仓库操作记录页面及相关统计图表功能
This commit is contained in:
砂糖
2026-04-01 14:50:56 +08:00
parent f959f97099
commit 579bf3796f
19 changed files with 677 additions and 47 deletions

View File

@@ -137,6 +137,10 @@
<span class="param-label">镀层种类</span>
<span class="param-value">{{ item.coatingType }}</span>
</div>
<div class="param-row" v-if="item.coilSurfaceTreatment">
<span class="param-label">钢卷表面处理</span>
<span class="param-value">{{ item.coilSurfaceTreatment }}</span>
</div>
<div class="param-row" v-if="item.team">
<span class="param-label">班组</span>
<span class="param-value">{{ item.team }}</span>
@@ -349,6 +353,9 @@
<el-form-item label="镀层种类" prop="coatingType">
<MemoInput storageKey="coatingType" v-model="form.coatingType" placeholder="请输入镀层种类" />
</el-form-item>
<el-form-item label="钢卷表面处理" prop="coilSurfaceTreatment">
<MemoInput storageKey="surfaceTreatmentDesc" v-model="form.coilSurfaceTreatment" placeholder="请输入钢卷表面处理" />
</el-form-item>
<el-form-item label="备注" prop="remark">
<el-input v-model="form.remark" placeholder="请输入备注" />
</el-form-item>

View File

@@ -128,6 +128,10 @@
<span class="param-label">镀层种类</span>
<span class="param-value">{{ item.coatingType }}</span>
</div>
<div class="param-row" v-if="item.coilSurfaceTreatment">
<span class="param-label">钢卷表面处理</span>
<span class="param-value">{{ item.coilSurfaceTreatment }}</span>
</div>
<div class="param-row" v-if="item.team">
<span class="param-label">班组</span>
<span class="param-value">{{ item.team }}</span>
@@ -423,6 +427,9 @@
<el-form-item label="镀层种类" prop="coatingType">
<MemoInput storageKey="coatingType" v-model="form.coatingType" placeholder="请输入镀层种类" />
</el-form-item>
<el-form-item label="钢卷表面处理" prop="coilSurfaceTreatment">
<MemoInput storageKey="surfaceTreatmentDesc" v-model="form.coilSurfaceTreatment" placeholder="请输入钢卷表面处理" />
</el-form-item>
<el-form-item label="备注" prop="remark">
<el-input v-model="form.remark" placeholder="请输入备注" />
</el-form-item>

View File

@@ -222,13 +222,20 @@
</el-form-item>
</div>
<el-form-item label="钢卷表面处理" prop="coilSurfaceTreatment" class="form-item-half">
<MemoInput storageKey="surfaceTreatmentDesc" v-model="targetCoil.coilSurfaceTreatment"
placeholder="请输入钢卷表面处理" />
</el-form-item>
<!-- <div class="form-row"> -->
<el-form-item label="生产开始时间" prop="productionStartTime" class="form-item-half">
<TimeInput v-model="targetCoil.productionStartTime" @input="calculateProductionDuration" :disabled="readonly" />
</el-form-item>
<el-form-item label="生产结束时间" prop="productionEndTime" class="form-item-half">
<TimeInput v-model="targetCoil.productionEndTime" @input="calculateProductionDuration" :disabled="readonly" :show-now-button="true" />
</el-form-item>
<el-form-item label="生产开始时间" prop="productionStartTime" class="form-item-half">
<TimeInput v-model="targetCoil.productionStartTime" @input="calculateProductionDuration"
:disabled="readonly" />
</el-form-item>
<el-form-item label="生产结束时间" prop="productionEndTime" class="form-item-half">
<TimeInput v-model="targetCoil.productionEndTime" @input="calculateProductionDuration"
:disabled="readonly" :show-now-button="true" />
</el-form-item>
<!-- </div> -->
<div class="form-row">
@@ -240,30 +247,18 @@
<div class="form-row">
<el-form-item label="异常信息" class="form-item-full">
<div class="abnormal-container">
<div
v-for="(abnormal, index) in abnormals"
:key="index"
class="abnormal-item"
@click="editAbnormal(index)"
>
<div v-for="(abnormal, index) in abnormals" :key="index" class="abnormal-item"
@click="editAbnormal(index)">
<div class="abnormal-content">
<div class="abnormal-info">
<div class="abnormal-position">{{ getAbnormalPositionText(abnormal.position) }}</div>
<div class="abnormal-code">{{ getAbnormalCodeText(abnormal.defectCode) }}</div>
</div>
<el-button
type="danger"
size="mini"
icon="el-icon-close"
class="abnormal-delete"
@click.stop="deleteAbnormal(index)"
></el-button>
<el-button type="danger" size="mini" icon="el-icon-close" class="abnormal-delete"
@click.stop="deleteAbnormal(index)"></el-button>
</div>
</div>
<div
class="abnormal-add"
@click="addAbnormal"
>
<div class="abnormal-add" @click="addAbnormal">
<i class="el-icon-plus"></i>
</div>
</div>
@@ -276,16 +271,9 @@
</div>
<!-- 异常表单弹窗 -->
<el-dialog
:title="currentAbnormalIndex === -1 ? '新增异常' : '编辑异常'"
:visible.sync="abnormalDialogVisible"
width="600px"
>
<abnormal-form
ref="abnormalForm"
v-model="abnormalForm"
:show-coil-selector="false"
></abnormal-form>
<el-dialog :title="currentAbnormalIndex === -1 ? '新增异常' : '编辑异常'" :visible.sync="abnormalDialogVisible"
width="600px">
<abnormal-form ref="abnormalForm" v-model="abnormalForm" :show-coil-selector="false"></abnormal-form>
<div slot="footer" class="dialog-footer">
<el-button @click="abnormalDialogVisible = false"> </el-button>
<el-button type="primary" @click="saveAbnormal"> </el-button>
@@ -858,20 +846,20 @@ export default {
// 格式化毫秒值为xx天xx小时xx分钟
formatDuration(milliseconds) {
if (!milliseconds || milliseconds < 0) return '';
const seconds = Math.floor(milliseconds / 1000);
const minutes = Math.floor(seconds / 60);
const hours = Math.floor(minutes / 60);
const days = Math.floor(hours / 24);
const remainingHours = hours % 24;
const remainingMinutes = minutes % 60;
let result = '';
if (days > 0) result += `${days}`;
if (remainingHours > 0) result += `${remainingHours}小时`;
if (remainingMinutes > 0) result += `${remainingMinutes}分钟`;
return result || '0分钟';
},
// 计算生产耗时
@@ -902,7 +890,7 @@ export default {
closePage() {
this.$router.back();
},
// 新增异常
addAbnormal() {
this.currentAbnormalIndex = -1;
@@ -918,21 +906,21 @@ export default {
};
this.abnormalDialogVisible = true;
},
// 编辑异常
editAbnormal(index) {
this.currentAbnormalIndex = index;
this.abnormalForm = { ...this.abnormals[index] };
this.abnormalDialogVisible = true;
},
// 保存异常
saveAbnormal() {
this.$refs.abnormalForm.validate(valid => {
if (valid) {
// 计算缺陷长度
this.abnormalForm.length = this.abnormalForm.endPosition - this.abnormalForm.startPosition;
if (this.currentAbnormalIndex === -1) {
// 新增异常
this.abnormals.push({ ...this.abnormalForm });
@@ -940,12 +928,12 @@ export default {
// 编辑异常
this.abnormals[this.currentAbnormalIndex] = { ...this.abnormalForm };
}
this.abnormalDialogVisible = false;
}
});
},
// 删除异常
deleteAbnormal(index) {
this.$confirm('确定要删除这个异常信息吗?', '提示', {
@@ -956,7 +944,7 @@ export default {
this.abnormals.splice(index, 1);
});
},
// 获取异常位置文本
getAbnormalPositionText(position) {
if (!position) return '';
@@ -965,7 +953,7 @@ export default {
const item = dict.find(item => item.value === position);
return item ? item.label : position;
},
// 获取异常代码文本
getAbnormalCodeText(code) {
if (!code) return '';

View File

@@ -394,6 +394,9 @@
<el-form-item label="镀层种类" prop="coatingType">
<MemoInput storageKey="coatingType" v-model="form.coatingType" placeholder="请输入镀层种类" />
</el-form-item>
<el-form-item label="钢卷表面处理" prop="coilSurfaceTreatment">
<MemoInput storageKey="surfaceTreatmentDesc" v-model="form.coilSurfaceTreatment" placeholder="请输入钢卷表面处理" />
</el-form-item>
<el-form-item label="备注" prop="remark">
<el-input v-model="form.remark" placeholder="请输入备注" />
</el-form-item>
@@ -796,6 +799,8 @@ export default {
{ label: '镀层种类', prop: 'coatingType' },
{ label: '实测长度(m)', prop: 'actualLength' },
{ label: '实测宽度(m)', prop: 'actualWidth' },
{ label: '实测厚度(m)', prop: 'actualThickness' },
{ label: '钢卷表面处理', prop: 'coilSurfaceTreatment' },
],
title: '详细信息'
},

View File

@@ -123,6 +123,10 @@
<span class="param-label">镀层种类</span>
<span class="param-value">{{ item.coatingType }}</span>
</div>
<div class="param-row" v-if="item.coilSurfaceTreatment">
<span class="param-label">钢卷表面处理</span>
<span class="param-value">{{ item.coilSurfaceTreatment }}</span>
</div>
<div class="param-row" v-if="item.team">
<span class="param-label">班组</span>
<span class="param-value">{{ item.team }}</span>

View File

@@ -34,6 +34,10 @@
<el-descriptions-item label="规格">{{ coilInfo.specification || '-' }}</el-descriptions-item>
<el-descriptions-item label="材质">{{ coilInfo.material || '-' }}</el-descriptions-item>
<el-descriptions-item label="原料材质">{{ coilInfo.packingStatus || '-' }}</el-descriptions-item>
<el-descriptions-item label="实测长度(m)">{{ coilInfo.actualLength || '-' }}</el-descriptions-item>
<el-descriptions-item label="实测宽度(m)">{{ coilInfo.actualWidth || '-' }}</el-descriptions-item>
<el-descriptions-item label="实测厚度(m)">{{ coilInfo.actualThickness || '-' }}</el-descriptions-item>
<el-descriptions-item label="钢卷表面处理">{{ coilInfo.coilSurfaceTreatment || '-' }}</el-descriptions-item>
<el-descriptions-item label="净重">{{ coilInfo.netWeight || '-' }} T</el-descriptions-item>
</el-descriptions>
<!-- 已分条钢卷列表 -->
@@ -175,6 +179,9 @@
<el-form-item label="镀层种类" prop="coatingType">
<MemoInput storageKey="coatingType" v-model="splitForm.coatingType" placeholder="请输入镀层种类" />
</el-form-item>
<el-form-item label="钢卷表面处理" prop="coilSurfaceTreatment">
<MemoInput storageKey="surfaceTreatmentDesc" v-model="splitForm.coilSurfaceTreatment" placeholder="请输入钢卷表面处理" />
</el-form-item>
<el-form-item label="生产开始时间" prop="productionStartTime">
<TimeInput v-model="splitForm.productionStartTime" @input="calculateProductionDuration" />
</el-form-item>
@@ -257,6 +264,7 @@
<el-descriptions-item label="调制度">{{ selectedSplitItem.temperGrade || '-' }}</el-descriptions-item>
<el-descriptions-item label="镀层种类">{{ selectedSplitItem.coatingType || '-' }}</el-descriptions-item>
<el-descriptions-item label="钢卷表面处理">{{ selectedSplitItem.coilSurfaceTreatment || '-' }}</el-descriptions-item>
<el-descriptions-item label="生产开始时间">{{ selectedSplitItem.productionStartTime || '-'
}}</el-descriptions-item>
<el-descriptions-item label="生产结束时间">{{ selectedSplitItem.productionEndTime || '-'

View File

@@ -61,6 +61,10 @@
<span class="label">镀层种类</span>
<span class="value">{{ motherCoil.coatingType || '—' }}</span>
</div>
<div class="coil-info-row">
<span class="label">钢卷表面处理</span>
<span class="value">{{ motherCoil.coilSurfaceTreatment || '—' }}</span>
</div>
<div class="coil-info-row" v-if="motherCoil.materialName || motherCoil.productName">
<span class="label">物料名称</span>
<span class="value">{{ motherCoil.materialName || motherCoil.productName || '—' }}</span>
@@ -217,6 +221,9 @@
<el-form-item label="镀层种类" prop="coatingType">
<MemoInput storageKey="coatingType" v-model="item.coatingType" placeholder="请输入镀层种类" />
</el-form-item>
<el-form-item label="钢卷表面处理" prop="coilSurfaceTreatment">
<MemoInput storageKey="surfaceTreatmentDesc" v-model="item.coilSurfaceTreatment" placeholder="请输入钢卷表面处理" />
</el-form-item>
<el-form-item label="逻辑库区" required>
<WarehouseSelect v-model="item.warehouseId" placeholder="请选择逻辑库区" :disabled="readonly" />
</el-form-item>

View File

@@ -60,6 +60,10 @@
<span class="info-label">原料材质</span>
<span class="info-value">{{ currentInfo.packingStatus || '—' }}</span>
</div>
<div class="info-row">
<span class="info-label">钢卷表面处理</span>
<span class="info-value">{{ currentInfo.coilSurfaceTreatment || '—' }}</span>
</div>
<div class="info-row">
<span class="info-label">厂家</span>
<span class="info-value">{{ currentInfo.manufacturer || '—' }}</span>
@@ -211,6 +215,10 @@
<MemoInput storageKey="coatingType" v-model="updateForm.coatingType" placeholder="请输入镀层种类" />
</el-form-item>
<el-form-item label="钢卷表面处理" prop="coilSurfaceTreatment">
<MemoInput storageKey="surfaceTreatmentDesc" v-model="updateForm.coilSurfaceTreatment" placeholder="请输入钢卷表面处理" />
</el-form-item>
<el-form-item label="逻辑库区" prop="warehouseId">
<WarehouseSelect v-model="updateForm.warehouseId" placeholder="请选择逻辑库区" />
</el-form-item>