修改头码车运行bug

This commit is contained in:
joylink_zhangsai 2021-05-28 17:49:53 +08:00
parent 0a2ea4ad09
commit 5dbba35cdf

View File

@ -1002,7 +1002,9 @@ public class Section extends MayOutOfOrderDevice {
}
public boolean isAheadOf(SimulationDataRepository repository, Section other, boolean right) {
List<RoutePath> routePaths = repository.queryRoutePaths(other, this);
List<RoutePath> routePaths = repository.queryRoutePathsByEndAndContainsSection(this, other);
if (CollectionUtils.isEmpty(routePaths))
return false;
for (RoutePath routePath : routePaths) {
if (routePath.isRight() == right)
return true;