道岔信号机字段调整

This commit is contained in:
joylink_cuiweidong 2021-09-10 15:26:25 +08:00
parent d541259695
commit a271f99163
2 changed files with 12 additions and 9 deletions

View File

@ -826,8 +826,6 @@ class Signal extends Group {
} }
if (this.style.Signal.post.autoRouteColor) { if (this.style.Signal.post.autoRouteColor) {
this.sigPost.setColor(this.style.Signal.post.autoRouteColor); this.sigPost.setColor(this.style.Signal.post.autoRouteColor);
} else if (this.style.Signal.post.autoRouteVerColor) {
this.sigPost.setVerColor(this.style.Signal.post.autoRouteVerColor);
} }
} }
@ -1056,12 +1054,15 @@ class Signal extends Group {
}); });
} }
} }
// LEVEL_Close = 0;---关闭 LEVEL_Guide = 1;-----引导级 LEVEL_Atp = 2;-----ATP级 LEVEL_Main = 3-----主信号级
if ( model.level === 3 && this.style.Signal.post.mainSignalVerColor && !model.fleetMode) { if ( model.level === 3 && this.style.Signal.post.mainSignalVerColor && !model.fleetMode) {
this.sigPost.setVerColor(this.style.Signal.post.mainSignalVerColor); this.sigPost.setVerColor(this.style.Signal.post.mainSignalVerColor);
} else if (model.level === 1 && this.style.Signal.post.closeSignalVerColor && !model.fleetMode) { } else if (model.level === 0 && this.style.Signal.post.closeSignalVerColor && !model.fleetMode) {
this.sigPost.setVerColor(this.style.Signal.post.closeSignalVerColor); this.sigPost.setVerColor(this.style.Signal.post.closeSignalVerColor);
} else if (model.level === 2 && this.style.Signal.post.guideSignalVerColor && !model.fleetMode) { } else if (model.level === 1 && this.style.Signal.post.guideSignalVerColor && !model.fleetMode) {
this.sigPost.setVerColor(this.style.Signal.post.guideSignalVerColor); this.sigPost.setVerColor(this.style.Signal.post.guideSignalVerColor);
} else if (model.level === 2 && this.style.Signal.post.autoRouteVerColor && !model.fleetMode) {
this.sigPost.setVerColor(this.style.Signal.post.autoRouteVerColor);
} }
if (this.style.Signal.lamp.special) { if (this.style.Signal.lamp.special) {
@ -1081,7 +1082,7 @@ class Signal extends Group {
this.tText && this.tText.show(); this.tText && this.tText.show();
} }
// 设置灰显 // 设置灰显
if (model.noStatus || model.level === 0) { if (model.noStatus) {
this.setAshShow(); this.setAshShow();
} }

View File

@ -436,7 +436,7 @@ export default class Switch extends Group {
// N-定位 R-反位 NO-无(失表) EX-挤叉 // N-定位 R-反位 NO-无(失表) EX-挤叉
setSwitchFault(fault, pos) { setSwitchFault(fault, pos) {
if (this.style.Switch.jointImg.faultStatus && fault && (pos == 'NO' || pos == 'EX') ) { // 宁波线失表状态 if (this.style.Switch.jointImg.faultStatus && fault && (pos == 'NO' || pos == 'EX') ) { // 宁波线失表状态
this.setForkAction(); // 道岔挤岔 this.setForkAction(fault); // 道岔挤岔
} else if (this.style.Switch.faultNoHandle ) { } else if (this.style.Switch.faultNoHandle ) {
this.shapeModelA.hide(); this.shapeModelA.hide();
this.shapeModelB.hide(); this.shapeModelB.hide();
@ -457,7 +457,7 @@ export default class Switch extends Group {
} }
} }
/** 挤叉*/ /** 挤叉*/
setForkAction() { setForkAction(fault) {
if (this.style.Switch.jointImg.fork) { if (this.style.Switch.jointImg.fork) {
this.recover(); this.recover();
this.shapeModelB.show(); this.shapeModelB.show();
@ -485,6 +485,8 @@ export default class Switch extends Group {
.start(); .start();
}); });
this.setTextColor('red'); this.setTextColor('red');
} else {
this.setLossAction(fault); // 若不是具有特殊的挤岔,则显示状态和失表一样
} }
} }
@ -710,7 +712,7 @@ export default class Switch extends Group {
} else if (model.pos == 'NO') { } else if (model.pos == 'NO') {
this.setLossAction(model.fault); // 失去 this.setLossAction(model.fault); // 失去
} else if (model.pos == 'EX') { } else if (model.pos == 'EX') {
this.setForkAction(); // 挤岔 this.setForkAction(model.fault); // 挤岔
} }
model.isCiConfirm && this.setCiConfirm(); // 道岔使能显示 model.isCiConfirm && this.setCiConfirm(); // 道岔使能显示