闭塞状态 代码调整
This commit is contained in:
parent
c01e352610
commit
50c0f3abaf
@ -963,6 +963,8 @@ class SkinCode extends defaultStyle {
|
||||
defaultColor: '#ccc',
|
||||
occupiedColor:'#f00',
|
||||
noOccupiedColor:'#00ff00',
|
||||
blockStatusColor:'#00ff00',
|
||||
noBlockStatusColor:'#ffff00',
|
||||
};
|
||||
this[deviceType.PickArrow] = {
|
||||
triangleLength: 15,
|
||||
@ -976,6 +978,8 @@ class SkinCode extends defaultStyle {
|
||||
defaultColor: '#ccc',
|
||||
occupiedColor:'#f00',
|
||||
noOccupiedColor:'#ffff00',
|
||||
blockStatusColor:'#00ff00',
|
||||
noBlockStatusColor:'#ffff00',
|
||||
};
|
||||
this[deviceType.Occlusion] = {
|
||||
text: {
|
||||
|
@ -481,7 +481,15 @@ class Jlmap {
|
||||
const selectButtonList = signalButtonList.filter(elem=>{
|
||||
return elem.labelEnum === directionData.labelEnum && elem.stationCode == directionData.stationCode;
|
||||
});
|
||||
const selectMap = {'ASSIST':'mainAssistStatus', 'PICK_ASSIST':'receiveAssistStatus', 'DEPART_ASSIST':'deliverAssistStatus', 'CHANGE_DIRECTION':'changeDirectionStatus'};
|
||||
const selectMap = {'ASSIST':'mainAssistStatus',
|
||||
'PICK_ASSIST':'receiveAssistStatus',
|
||||
'DEPART_ASSIST':'deliverAssistStatus',
|
||||
'CHANGE_DIRECTION':'changeDirectionStatus',
|
||||
// 闭塞按钮
|
||||
'OCCLUSION':'blockStatus',
|
||||
// 复原按钮
|
||||
'RECOVERY':'restoreStatus'
|
||||
};
|
||||
// { value: 'ASSIST', label: '总辅助按钮' },
|
||||
// { value: 'PICK_ASSIST', label: '接辅助按钮' },
|
||||
// { value: 'DEPART_ASSIST', label: '发辅助按钮' },
|
||||
@ -509,6 +517,9 @@ class Jlmap {
|
||||
if (elem.receiveAspect != undefined) {
|
||||
model.aspect = elem.receiveAspect;
|
||||
}
|
||||
if (elem.blockStatus != undefined ) {
|
||||
model.blockStatus = elem.blockStatus;
|
||||
}
|
||||
this.$painter.update(model);
|
||||
}
|
||||
break;
|
||||
@ -520,6 +531,9 @@ class Jlmap {
|
||||
if (elem.deliverAspect != undefined) {
|
||||
model.aspect = elem.deliverAspect;
|
||||
}
|
||||
if (elem.blockStatus != undefined ) {
|
||||
model.blockStatus = elem.blockStatus;
|
||||
}
|
||||
this.$painter.update(model);
|
||||
}
|
||||
break;
|
||||
|
@ -220,6 +220,20 @@ export default class SaidLamp extends Group {
|
||||
}
|
||||
} else if (model.runStatus == 'D') { // 发车
|
||||
this.control && this.control.setControlColor(this.deviceStyle.fill);
|
||||
} else if (model.runStatus == 'S') { // 闭塞
|
||||
// blockStatus:false * 指示灯(F)的时候为黄色,true为绿色
|
||||
// 指示灯(O)为红色
|
||||
if (model.blockStatus != undefined) {
|
||||
if (model.aspect == 'O') {
|
||||
this.control && this.control.setControlColor(this.deviceStyle.occupiedColor);
|
||||
} else if (model.aspect == 'F') {
|
||||
if (model.blockStatus) {
|
||||
this.control && this.control.setControlColor(this.deviceStyle.blockStatusColor);
|
||||
} else {
|
||||
this.control && this.control.setControlColor(this.deviceStyle.noBlockStatusColor);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
} else if (model._type == deviceType.DepartArrow) { // 发车灯
|
||||
if (model.runStatus == 'D') { // 发车
|
||||
@ -231,6 +245,18 @@ export default class SaidLamp extends Group {
|
||||
}
|
||||
} else if (model.runStatus == 'R') { // 接车
|
||||
this.control && this.control.setControlColor(this.deviceStyle.fill);
|
||||
} else if (model.runStatus == 'S') { // 闭塞
|
||||
if (model.blockStatus != undefined) {
|
||||
if (model.aspect == 'O') {
|
||||
this.control && this.control.setControlColor(this.deviceStyle.occupiedColor);
|
||||
} else if (model.aspect == 'F') {
|
||||
if (model.blockStatus) {
|
||||
this.control && this.control.setControlColor(this.deviceStyle.blockStatusColor);
|
||||
} else {
|
||||
this.control && this.control.setControlColor(this.deviceStyle.noBlockStatusColor);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
} else {
|
||||
switch (model.aspect) {
|
||||
|
@ -643,7 +643,7 @@ export default {
|
||||
this.clearOperate();
|
||||
}
|
||||
} else if (!buttonOperation) {
|
||||
const signalButtonList = ['ASSIST', 'CHANGE_DIRECTION', 'PICK_ASSIST', 'DEPART_ASSIST'];
|
||||
const signalButtonList = ['ASSIST', 'CHANGE_DIRECTION', 'PICK_ASSIST', 'DEPART_ASSIST', 'OCCLUSION', 'RECOVERY'];
|
||||
if (model._type === 'SignalButton' && !this.checkSignalBlock(model.signalCode) && model.type === 'GUIDE' ) {
|
||||
this.handleGuideSignal(model);
|
||||
} else if (model._type === 'SignalButton' && signalButtonList.includes(model.type)) {
|
||||
@ -712,8 +712,8 @@ export default {
|
||||
stationCode:model.stationCode
|
||||
}
|
||||
},
|
||||
// 阻塞
|
||||
'':{
|
||||
// 闭塞按钮
|
||||
'OCCLUSION':{
|
||||
operation:this.CTCCommand.assistPressBlock.menu.operation,
|
||||
nextCmdType:CMD.CTC.CTC_ASSIST_PRESS_BLOCK,
|
||||
param:{
|
||||
@ -721,8 +721,8 @@ export default {
|
||||
stationCode:model.stationCode
|
||||
}
|
||||
},
|
||||
// 复原
|
||||
'':{
|
||||
// 复原按钮
|
||||
'RECOVERY':{
|
||||
operation:this.CTCCommand.assistPressRestore.menu.operation,
|
||||
nextCmdType:CMD.CTC.CTC_ASSIST_PRESS_RESTORE,
|
||||
param:{
|
||||
|
Loading…
Reference in New Issue
Block a user