修改设置头码车逻辑
This commit is contained in:
parent
ac063978f8
commit
cd8efe1a21
@ -260,24 +260,22 @@ public class AtsTrainService {
|
|||||||
default:
|
default:
|
||||||
throw new SimulationException(SimulationExceptionType.System_Fault, String.format("无法识别的目的地码类型[%s]", destinationCodeDefinition.getType()));
|
throw new SimulationException(SimulationExceptionType.System_Fault, String.format("无法识别的目的地码类型[%s]", destinationCodeDefinition.getType()));
|
||||||
}
|
}
|
||||||
supervisedTrain.change2HeadCode(destinationCode, serviceNumber, tripNumber);
|
|
||||||
//默认
|
//默认
|
||||||
this.onboardAtpApiService.update2HeadTrainServiceNumber(simulation, groupNumber, serviceNumber, tripNumber, destinationCode, true);
|
|
||||||
} else { //没有新版目的地码数据
|
} else { //没有新版目的地码数据
|
||||||
List<Routing> routingList = repository.queryRoutingByDestCode(destinationCode);
|
List<Routing> routingList = repository.queryRoutingByDestCode(destinationCode);
|
||||||
if (CollectionUtils.isEmpty(routingList)) {
|
if (CollectionUtils.isEmpty(routingList)) {
|
||||||
throw new SimulationException(SimulationExceptionType.Operation_Handle_FAIL,
|
throw new SimulationException(SimulationExceptionType.Operation_Handle_FAIL,
|
||||||
String.format("不存在目的地号为[%s]的交路", destinationCode));
|
String.format("不存在目的地号为[%s]的交路", destinationCode));
|
||||||
} else {
|
|
||||||
boolean needParking = true;
|
|
||||||
if (repository.getConfig().isNoParkingServiceNumber(serviceNumber)) {
|
|
||||||
needParking = false;
|
|
||||||
}
|
|
||||||
supervisedTrain.change2HeadCode(destinationCode, serviceNumber, tripNumber);
|
|
||||||
//默认
|
|
||||||
this.onboardAtpApiService.update2HeadTrainServiceNumber(simulation, groupNumber, serviceNumber, tripNumber, destinationCode, needParking);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
boolean needParking = true;
|
||||||
|
if (repository.getConfig().isNoParkingServiceNumber(serviceNumber)) {
|
||||||
|
needParking = false;
|
||||||
|
}
|
||||||
|
supervisedTrain.change2HeadCode(destinationCode, serviceNumber, tripNumber);
|
||||||
|
this.onboardAtpApiService.update2HeadTrainServiceNumber(simulation, groupNumber, serviceNumber, tripNumber, destinationCode, needParking);
|
||||||
|
supervisedTrain.updateEstimatedArriveInfo(null, null);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -801,6 +801,7 @@ public class RouteService {
|
|||||||
}
|
}
|
||||||
//进路解锁
|
//进路解锁
|
||||||
route.setLock(false);
|
route.setLock(false);
|
||||||
|
route.setSetting(false);
|
||||||
simulation.getRepository().removeSettingRoute(route);
|
simulation.getRepository().removeSettingRoute(route);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user