fix:堆垛机对接位入库,查询时排除行架任务

This commit is contained in:
2024-08-21 08:54:32 +08:00
parent 0e6e8eeef9
commit ee2b8cf250
2 changed files with 4 additions and 1 deletions

View File

@@ -504,8 +504,11 @@ public class BeltConveyorDeviceDriver extends AbstractOpcDeviceDriver implements
requireSucess = true;
return true;
} else {
//移除行架任务
//查看是否存在输送线到对接为的指令
Instruction byNextDeviceCodeFromCache = instructionService.findByNextDeviceCodeFromCache(this.device_code);
if (ObjectUtil.isNotEmpty(byNextDeviceCodeFromCache)) {
LuceneLogDto logDto = LuceneLogDto.builder()
.device_code(device_code)

View File

@@ -1665,7 +1665,7 @@ public class InstructionServiceImpl extends CommonServiceImpl<InstructionMapper,
Iterator<Instruction> it = instructions.iterator();
while (it.hasNext()) {
Instruction inst = it.next();
if (StrUtil.equals(devicecode, inst.getNext_device_code()) && Integer.parseInt(inst.getInstruction_status()) <= Integer.parseInt(InstructionStatusEnum.BUSY.getIndex())) {
if (StrUtil.equals(devicecode, inst.getNext_device_code()) && Integer.parseInt(inst.getInstruction_status()) <= Integer.parseInt(InstructionStatusEnum.BUSY.getIndex()) && !inst.getInstruction_type().equals(TaskTypeEnum.Truss_Task.getIndex()) ) {
return inst;
}
}