南京二 实训问题处理

This commit is contained in:
Jade 2021-11-24 10:46:07 +08:00
parent 5130b67ddd
commit 68ebd521d8
4 changed files with 20 additions and 7 deletions

View File

@ -60,7 +60,8 @@ public class StandGeneratorNew implements GeneratorNew {
break;
}
case Stand_Force_Cancel_Hold_Train:
stand.setCenterHoldTrain(true);
case Stand_Cancel_Setting:
stand.setCenterHoldTrain(true);
break;
case Stand_Cancel_Hold_Train:
case Stand_Cancel_Hold_Train_Batch: {

View File

@ -249,6 +249,10 @@ public class StationGeneratorNew implements GeneratorNew {
}
station.setInterlockMachineStarting(true);
break;
case Station_Release:
if(!station.isInterlock())continue;
Station.Fault.INTERLOCK_FAULT.apply(station);
break;
default:
// 其他操作不生成
continue;

View File

@ -94,10 +94,13 @@ public class SwitchGeneratorNew implements GeneratorNew {
break;
}
case Switch_Fault_Unlock:{
// 背景为道岔区段故障锁闭
aSwitch.getA().setFaultLock(true);
aSwitch.getB().setFaultLock(true);
aSwitch.getC().setFaultLock(true);
// // 背景为道岔区段故障锁闭
// aSwitch.getA().setFaultLock(true);
// aSwitch.getB().setFaultLock(true);
// aSwitch.getC().setFaultLock(true);
aSwitch.setRouteLock(true);
aSwitch.getA().setRouteLock(true);
aSwitch.getB().setRouteLock(true);
break;
}
case Switch_Axle_Pre_Reset:{

View File

@ -258,8 +258,13 @@ public class CiApiServiceImpl2 implements CiApiService {
}
}
}
for (Route lockedRoute : lockSwitchRoutes) {
this.routeService.switchFaultUnlock(simulation, aSwitch, lockedRoute);
if (!lockSwitchRoutes.isEmpty()) {
for (Route lockedRoute : lockSwitchRoutes) {
this.routeService.switchFaultUnlock(simulation, aSwitch, lockedRoute);
}
} else {
aSwitch.faultUnlock();
aSwitch.sectionFaultUnlock();
}
}