| | |
| | | int currentLev = Utils.getLev(currentLocNo); |
| | | //判断当前楼层是否有任务,如果有则不分配这辆车 |
| | | List<WrkMast> wrkMasts1 = wrkMastService.selectWrkByLev(currentLev); |
| | | int shuttleCount = this.getShuttleEnableUseCountByLev(currentLev);//获取穿梭车楼层车辆数量 |
| | | if (!wrkMasts1.isEmpty() && shuttleCount <= 1) { |
| | | int currentLevTaskCount = wrkMasts1.size(); |
| | | for (WrkMast wrkMast : wrkMasts1) { |
| | | if (wrkMast.getIoType() == WrkIoType.SHUTTLE_CHARGE.id) { |
| | | currentLevTaskCount--; |
| | | } |
| | | } |
| | | int shuttleCount = this.getShuttleCountByLev(currentLev);//获取穿梭车楼层车辆数量 |
| | | if (currentLevTaskCount > 0 && shuttleCount <= 1) { |
| | | //存在其他任务且可用小车数量小于等于1,跳过这辆车 |
| | | continue; |
| | | } |
| | |
| | | return false; |
| | | } |
| | | |
| | | if (shuttleProtocol.getCurrentLocNo().equals(locNo)) { |
| | | News.info("{}号小车,移动目标位置与小车当前位置一致无法移动", shuttleNo); |
| | | return false; |
| | | } |
| | | |
| | | //判断穿梭车是否存在未完成的小车移库任务 |
| | | WrkMast hasMoveWorking = wrkMastService.selectShuttleHasMoveWorking(shuttleNo); |
| | | if (hasMoveWorking != null) {//小车存在移库任务,等待执行完成后再生成新的任务 |