| | |
| | | |
| | | if (funcSta.getType().equals(FuncStaType.CHARGE.toString())) { |
| | | // if the type of this funSta is charge and the existing agv is in charge status, then that means this funSta is occupied |
| | | if (null != agv) { |
| | | if (null != agv && !agv.getId().equals(agvId)) { |
| | | AgvModel agvModel = agvModelService.getById(agv.getAgvModel()); |
| | | AgvDetail agvDetail = agvDetailService.selectByAgvId(agv.getId()); |
| | | if (agvDetail.getAgvStatus().equals(AgvStatusType.CHARGE)) { |
| | |
| | | } |
| | | |
| | | } else { |
| | | // if there is an agv on the code of this funSta, should we let this agv leave? |
| | | // we need to judge whether the agv went to this funSta based on a task which in GO_STANDBY type |
| | | if (!agv.getId().equals(agvId)) { |
| | | // if there is an agv on the code of this funSta, should we let this agv leave? |
| | | // we need to judge whether the agv went to this funSta based on a task which in GO_STANDBY type |
| | | |
| | | // Task latestTaskByAgv = taskService.findLatestTask(existAgv.getId()); |
| | | return false; |
| | | return false; |
| | | } |
| | | |
| | | } |
| | | } |
| | | |