fix: 入库异常口任务校验

This commit is contained in:
2024-04-24 14:03:36 +08:00
parent ca633ff27d
commit 01637beba9
7 changed files with 15 additions and 4 deletions

View File

@@ -603,10 +603,10 @@ public class BeltConveyorDeviceDriver extends AbstractOpcDeviceDriver implements
} else {
next_point_code = next_device_code;
}
//判断是否存在终点到达ddj对接位的指令
//判断是否存在终点到达ddj对接位的指令(包含货架到达ddj对接位的指令、输送线到对接位的指令)
Instruction byNextDeviceCodeDDJ = instructionService.findByNextDeviceCodeFromCache(next_device_code);
if (ObjectUtil.isNotEmpty(byNextDeviceCodeDDJ)) {
this.setNotCreateInstMessage("存在终点到达ddj对接位的指令");
this.setNotCreateInstMessage("存在相同路线的指令");
}
//判断下一个输送线点位是否有货
BeltConveyorDeviceDriver beltConveyorDeviceDriver;

View File

@@ -20,6 +20,7 @@ import org.nl.acs.device.service.impl.DeviceExtraServiceImpl;
import org.nl.acs.device_driver.DeviceDriver;
import org.nl.acs.device_driver.FeedLmsRealFailed;
import org.nl.acs.device_driver.RouteableDeviceDriver;
import org.nl.acs.device_driver.conveyor.belt_conveyor.BeltConveyorDeviceDriver;
import org.nl.acs.device_driver.driver.AbstractOpcDeviceDriver;
import org.nl.acs.device_driver.driver.ExecutableDeviceDriver;
import org.nl.acs.device_driver.led.led_screen.LedScreenDeviceDriver;
@@ -486,7 +487,10 @@ public class ConveyorWithScannerWeightDeviceDriver extends AbstractOpcDeviceDriv
Instruction instdto = new Instruction();
String interactionJson = taskdto.getInteraction_json();
InteractionJsonDTO interactionJsonDTO = JSON.parseObject(interactionJson, InteractionJsonDTO.class);
String containerType = interactionJsonDTO.getContainerType();
String containerType = "";
if (ObjectUtil.isNotEmpty(interactionJsonDTO)) {
containerType = interactionJsonDTO.getContainerType();
}
if (TaskTypeEnum.AGV_Task.getIndex().equals(taskdto.getTask_type())){
String route_plan_code = taskdto.getRoute_plan_code();
@@ -508,6 +512,8 @@ public class ConveyorWithScannerWeightDeviceDriver extends AbstractOpcDeviceDriv
requireSucess = false;
return false;
}
packageInstrcutData(instdto, taskdto, taskid, taskcode, vehiclecode, priority,start_device_code,next_device_code,containerType);
}else {

View File

@@ -1535,7 +1535,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())) {
if (StrUtil.equals(devicecode, inst.getNext_device_code()) && Integer.parseInt(inst.getInstruction_status())<=Integer.parseInt(InstructionStatusEnum.BUSY.getIndex())) {
return inst;
}
}