fix(warning): 解决退火工序告警处理问题

- 退火工序没有actionId时不创建代操作记录,直接设置actionType=600
- 当actionId为空时使用bo中的actionType作为兜底方案
- 确保退火工序的告警能够正确关联到对应的操作类型
This commit is contained in:
2026-06-12 16:00:34 +08:00
parent e0cf4b46b6
commit 36b1e3da82
2 changed files with 8 additions and 0 deletions

View File

@@ -1870,6 +1870,10 @@ public class WmsMaterialCoilServiceImpl implements IWmsMaterialCoilService {
}
// 检查长度/厚度偏差并插入告警
// 退火工序没有actionId不创建代操作记录直接设置actionType=600
if ("annealing".equals(qrcodeStepType)) {
bo.setActionType(600);
}
materialWarningService.checkAndInsertWarnings(newCoil, bo);
// 如果实际库区id为-1则清空钢卷上的实际库区绑定

View File

@@ -198,6 +198,10 @@ public class WmsMaterialWarningServiceImpl implements IWmsMaterialWarningService
log.warn("查询产线类型失败, actionId={}", bo.getActionId(), e);
}
}
// 兜底如果没有actionId如退火工序不创建代操作记录直接使用bo中的actionType
if (actionType == null && bo != null && bo.getActionType() != null) {
actionType = bo.getActionType();
}
if (actionType != null) {
for (WmsMaterialWarning w : warnings) {
w.setActionType(actionType);