| | |
| | | if (wrkMast == null) { |
| | | continue; |
| | | } |
| | | BasCrnError crnError = basCrnErrorMapper.selectById(crnProtocol.getAlarm1()); |
| | | BasCrnError crnError = basCrnErrorMapper.selectById(crn.getId()==2?(crnProtocol.getAlarm1()+1000):crnProtocol.getAlarm1()); |
| | | String errName = crnError==null? String.valueOf(crnProtocol.getAlarm1()):crnError.getErrName(); |
| | | BasErrLog basErrLog = new BasErrLog( |
| | | null, // 编号 |
| | | wrkMast.getWrkNo(), // 工作号 |
| | |
| | | wrkMast.getSourceLocNo(), // 源库位 |
| | | wrkMast.getBarcode(), // 条码 |
| | | crnProtocol.getAlarm1().intValue(), // 异常码 |
| | | crnError.getErrName(), // 异常 |
| | | errName, // 异常 |
| | | 1, // 异常情况 |
| | | now, // 添加时间 |
| | | null, // 添加人员 |
| | |
| | | if (crnProtocol.getAlarm1() != null && crnProtocol.getAlarm1() > 0) { |
| | | // 记录新异常 |
| | | if (latest == null || (latest.getErrCode() != crnProtocol.getAlarm1().intValue())) { |
| | | BasCrnError crnError = basCrnErrorMapper.selectById(crnProtocol.getAlarm1()); |
| | | BasCrnError crnError = basCrnErrorMapper.selectById(crn.getId()==2?(crnProtocol.getAlarm1()+1000):crnProtocol.getAlarm1()); |
| | | String errName = crnError==null? String.valueOf(crnProtocol.getAlarm1()):crnError.getErrName(); |
| | | BasErrLog basErrLog = new BasErrLog( |
| | | null, // 编号 |