南京二 故障名称调整
This commit is contained in:
parent
b64065fb5b
commit
8fb2e6eb66
@ -194,6 +194,21 @@ export default {
|
|||||||
// return fault.value != 'NORMAL_SPLIT' && fault.value != 'REVERSE_SPLIT';
|
// return fault.value != 'NORMAL_SPLIT' && fault.value != 'REVERSE_SPLIT';
|
||||||
// });
|
// });
|
||||||
// }
|
// }
|
||||||
|
if (selected._type === 'Section' && this.popClass === 'haerbin-01__systerm') {
|
||||||
|
this.faultList = [
|
||||||
|
{label: '计轴故障', value: 'FAULT'},
|
||||||
|
{label: '通信车占用', value: 'CBTC_OCCUPIED_FAULT'}
|
||||||
|
];
|
||||||
|
} else if (selected._type === 'Switch' && this.popClass === 'haerbin-01__systerm') {
|
||||||
|
this.faultList = [
|
||||||
|
{label: '失表', value: 'SPLIT'},
|
||||||
|
{label: '定位失表', value: 'NORMAL_SPLIT'},
|
||||||
|
{label: '反位失表', value: 'REVERSE_SPLIT'},
|
||||||
|
{label: '挤岔', value: 'SQUEEZE'},
|
||||||
|
{label: '通信车占用', value: 'CBTC_OCCUPIED_FAULT'},
|
||||||
|
{label: '计轴故障', value: 'AXLE_FAULT'}
|
||||||
|
];
|
||||||
|
}
|
||||||
if (this.faultList && this.faultList.length) {
|
if (this.faultList && this.faultList.length) {
|
||||||
this.form.faultType = this.faultList[0].value;
|
this.form.faultType = this.faultList[0].value;
|
||||||
}
|
}
|
||||||
|
@ -35,9 +35,9 @@ class MenuContextHandler {
|
|||||||
return store.state.training.prdType;
|
return store.state.training.prdType;
|
||||||
}
|
}
|
||||||
|
|
||||||
getDeviceByCode(code) {
|
getDeviceByCode(code) {
|
||||||
return store.state.map.mapDevice[code];
|
return store.state.map.mapDevice[code];
|
||||||
}
|
}
|
||||||
|
|
||||||
// 判断指令是否隐藏
|
// 判断指令是否隐藏
|
||||||
checkDisabled(data, selected) {
|
checkDisabled(data, selected) {
|
||||||
@ -78,7 +78,7 @@ class MenuContextHandler {
|
|||||||
|
|
||||||
// 特殊处理站台的右键操作( 因为小站台不允许有操作 )
|
// 特殊处理站台的右键操作( 因为小站台不允许有操作 )
|
||||||
if (selected._type == 'StationStand' && selected.small) {
|
if (selected._type == 'StationStand' && selected.small) {
|
||||||
menu = [];
|
menu = [];
|
||||||
}
|
}
|
||||||
|
|
||||||
if (menu.constructor === Array) {
|
if (menu.constructor === Array) {
|
||||||
@ -110,7 +110,7 @@ class MenuContextHandler {
|
|||||||
}
|
}
|
||||||
// 特殊处理站台的右键操作( 因为小站台不允许有操作 )
|
// 特殊处理站台的右键操作( 因为小站台不允许有操作 )
|
||||||
if (selected._type == 'StationStand' && selected.small) {
|
if (selected._type == 'StationStand' && selected.small) {
|
||||||
menu = [];
|
menu = [];
|
||||||
}
|
}
|
||||||
if (menu.constructor === Array) {
|
if (menu.constructor === Array) {
|
||||||
menu.forEach(elem => {
|
menu.forEach(elem => {
|
||||||
@ -128,19 +128,19 @@ class MenuContextHandler {
|
|||||||
return menu;
|
return menu;
|
||||||
}
|
}
|
||||||
|
|
||||||
covertList(list) {
|
covertList(list) {
|
||||||
const menu = [...list];
|
const menu = [...list];
|
||||||
const selected = this.getCurrentStateObject();
|
const selected = this.getCurrentStateObject();
|
||||||
const control = this.getStationControl(selected);
|
const control = this.getStationControl(selected);
|
||||||
if (control && !store.state.scriptRecord.audioPlay) {
|
if (control && !store.state.scriptRecord.audioPlay) {
|
||||||
if (this.getPrdType() != '' && this.getPrdType() != null) {
|
if (this.getPrdType() != '' && this.getPrdType() != null) {
|
||||||
const type = State2SimulationMap[this.getPrdType()];
|
const type = State2SimulationMap[this.getPrdType()];
|
||||||
const status = State2ControlMap[control.controlMode]; // 判断当前模式
|
const status = State2ControlMap[control.controlMode]; // 判断当前模式
|
||||||
|
|
||||||
// 特殊处理站台的右键操作( 因为小站台不允许有操作 )
|
// 特殊处理站台的右键操作( 因为小站台不允许有操作 )
|
||||||
if (selected._type == 'StationStand' && selected.small) {
|
if (selected._type == 'StationStand' && selected.small) {
|
||||||
menu = [];
|
menu = [];
|
||||||
}
|
}
|
||||||
|
|
||||||
if (menu.constructor === Array) {
|
if (menu.constructor === Array) {
|
||||||
menu.forEach(elem => {
|
menu.forEach(elem => {
|
||||||
@ -156,7 +156,7 @@ class MenuContextHandler {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
return menu;
|
return menu;
|
||||||
}
|
}
|
||||||
|
|
||||||
covertEachCommand(elem, type, selected, status, isSettingCommand = true) {
|
covertEachCommand(elem, type, selected, status, isSettingCommand = true) {
|
||||||
if (elem.type === 'separator') {
|
if (elem.type === 'separator') {
|
||||||
@ -165,17 +165,17 @@ class MenuContextHandler {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const data = CommandHandler.getDefinition(elem.cmdType);
|
const data = CommandHandler.getDefinition(elem.cmdType);
|
||||||
const model = this.getDeviceByCode(selected.code);
|
const model = this.getDeviceByCode(selected.code);
|
||||||
|
|
||||||
if (data) {
|
if (data) {
|
||||||
// 判断指令是否显示
|
// 判断指令是否显示
|
||||||
if (data.simulationRole.toUpperCase() == type.toUpperCase() && data.controlMode.indexOf(status) > -1) {
|
if (data.simulationRole.toUpperCase() == type.toUpperCase() && data.controlMode.indexOf(status) > -1) {
|
||||||
elem.show = true;
|
elem.show = true;
|
||||||
elem.disabled = this.checkDisabled(data, model);
|
elem.disabled = this.checkDisabled(data, model);
|
||||||
if (!elem.disabled &&
|
if (!elem.disabled &&
|
||||||
elem.checkDisabled) {
|
elem.checkDisabled) {
|
||||||
elem.disabled = !!elem.checkDisabled(model);
|
elem.disabled = !!elem.checkDisabled(model);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
elem.show = true;
|
elem.show = true;
|
||||||
elem.disabled = true;
|
elem.disabled = true;
|
||||||
|
Loading…
Reference in New Issue
Block a user