diff --git a/src/main/java/club/joylink/rtss/services/draftData/DraftMapRouteServiceImpl.java b/src/main/java/club/joylink/rtss/services/draftData/DraftMapRouteServiceImpl.java index e6c74f4fc..a7b019c31 100644 --- a/src/main/java/club/joylink/rtss/services/draftData/DraftMapRouteServiceImpl.java +++ b/src/main/java/club/joylink/rtss/services/draftData/DraftMapRouteServiceImpl.java @@ -20,6 +20,7 @@ import club.joylink.rtss.vo.map.graph.MapSignalButtonVO; import club.joylink.rtss.vo.map.logic.MapRouteNewVO; import com.github.pagehelper.Page; import com.github.pagehelper.PageHelper; +import lombok.extern.slf4j.Slf4j; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; @@ -30,6 +31,7 @@ import java.util.*; import java.util.function.Function; import java.util.stream.Collectors; +@Slf4j @Service public class DraftMapRouteServiceImpl implements DraftMapRouteService { @@ -499,8 +501,12 @@ public class DraftMapRouteServiceImpl implements DraftMapRouteService { } Section next = section.getNextSection(right); if (next == null) { - BusinessExceptionAssertEnum.SYSTEM_EXCEPTION.assertTrue(section.isSwitchTrack() && section.getNextSection(!right) != null, - String.format("信号机[%s]未找到终端信号机", signal.getCode())); + if (!section.isSwitchTrack() || section.getNextSection(!right) == null) { + log.info(signal.debugStr() + "未找到通过进路的末端信号机"); + return; + } +// BusinessExceptionAssertEnum.SYSTEM_EXCEPTION.assertTrue(section.isSwitchTrack() && section.getNextSection(!right) != null, +// String.format("信号机[%s]未找到终端信号机", signal.getCode())); Switch relSwitch = section.getRelSwitch(); if (relSwitch.isA(section)) { next = relSwitch.getB();