| | |
| | | if (!Objects.equals(dispatchStationId, wrkMast.getStaNo()) |
| | | && isCurrentOutOrderStation(currentStationId, outOrderStationIds) |
| | | && isWatchingCircleArrival(wrkMast.getWrkNo(), currentStationId)) { |
| | | Integer circleTarget = resolveNextCircleOrderTarget(currentStationId, outOrderStationIds); |
| | | if (circleTarget == null) { |
| | | return null; |
| | | } |
| | | return new OutOrderDispatchDecision(circleTarget, true); |
| | | return new OutOrderDispatchDecision(dispatchStationId, true); |
| | | } |
| | | return new OutOrderDispatchDecision(dispatchStationId, false); |
| | | } |
| | |
| | | if (seq == null) { |
| | | toTarget = currentBatchSeq.equals(wrkMast.getBatchSeq()); |
| | | } else { |
| | | toTarget = Integer.valueOf(seq + 1).equals(wrkMast.getBatchSeq()) |
| | | && currentBatchSeq.equals(wrkMast.getBatchSeq()); |
| | | toTarget = Integer.valueOf(seq + 1).equals(wrkMast.getBatchSeq()); |
| | | } |
| | | if (toTarget) { |
| | | if (hasReachableOutReleaseSlot(currentStationId, wrkMast.getStaNo())) { |