Merge branch 'dev' of https://git.code.tencent.com/lian-cbtc/jl-client into dev
This commit is contained in:
commit
61ad60c365
@ -51,31 +51,31 @@ export default {
|
||||
menu: [],
|
||||
menuNormal: {
|
||||
Local: [
|
||||
{
|
||||
label: '区段故障解锁',
|
||||
handler: this.fault,
|
||||
cmdType: CMD.Section.CMD_SECTION_FAULT_UNLOCK
|
||||
},
|
||||
{
|
||||
label: '区段激活',
|
||||
handler: this.active,
|
||||
cmdType: CMD.Section.CMD_SECTION_ACTIVE
|
||||
},
|
||||
{
|
||||
label: '区段切除',
|
||||
handler: this.split,
|
||||
cmdType: CMD.Section.CMD_SECTION_CUT_OFF
|
||||
},
|
||||
{
|
||||
label: '区段计轴预复位',
|
||||
handler: this.axlePreReset,
|
||||
cmdType: CMD.Section.CMD_SECTION_AXIS_PRE_RESET
|
||||
},
|
||||
{
|
||||
label: '区段设置限速',
|
||||
handler: this.setSpeed,
|
||||
cmdType: CMD.Section.CMD_SECTION_SET_LIMIT_SPEED
|
||||
}
|
||||
// {
|
||||
// label: '区段故障解锁',
|
||||
// handler: this.faultUnlock,
|
||||
// cmdType: CMD.Section.CMD_SECTION_FAULT_UNLOCK
|
||||
// },
|
||||
// {
|
||||
// label: '区段激活',
|
||||
// handler: this.active,
|
||||
// cmdType: CMD.Section.CMD_SECTION_ACTIVE
|
||||
// },
|
||||
// {
|
||||
// label: '区段切除',
|
||||
// handler: this.split,
|
||||
// cmdType: CMD.Section.CMD_SECTION_CUT_OFF
|
||||
// },
|
||||
// {
|
||||
// label: '区段计轴预复位',
|
||||
// handler: this.axlePreReset,
|
||||
// cmdType: CMD.Section.CMD_SECTION_AXIS_PRE_RESET
|
||||
// },
|
||||
// {
|
||||
// label: '区段设置限速',
|
||||
// handler: this.setSpeed,
|
||||
// cmdType: CMD.Section.CMD_SECTION_SET_LIMIT_SPEED
|
||||
// }
|
||||
],
|
||||
Center: [
|
||||
{
|
||||
@ -172,14 +172,19 @@ export default {
|
||||
},
|
||||
operationHandler(buttonOperation, selectType) {
|
||||
switch (buttonOperation) {
|
||||
case OperationEvent.Signal.guide.button.operation: {
|
||||
case OperationEvent.Section.fault.menu.operation: {
|
||||
// 区故解
|
||||
if (selectType.fault) {
|
||||
this.faultUnlock(selectType);
|
||||
} else {
|
||||
this.$refs.noticeInfo.doShow({}, `该区段[${selectType.name}(${selectType.code})]没有故障`);
|
||||
}
|
||||
break;
|
||||
}
|
||||
case OperationEvent.Signal.guide.button.operation: {
|
||||
// 计轴复位
|
||||
break;
|
||||
}
|
||||
// case OperationEvent: {
|
||||
// // 计轴复位
|
||||
// break;
|
||||
// }
|
||||
}
|
||||
},
|
||||
// // 设置计轴失效
|
||||
@ -205,20 +210,19 @@ export default {
|
||||
// });
|
||||
// },
|
||||
// 故障解锁
|
||||
fault() {
|
||||
faultUnlock(selectType) {
|
||||
const operate = {
|
||||
start: true,
|
||||
code: this.selected.code,
|
||||
operation: OperationEvent.Section.fault.menu.operation,
|
||||
param: {
|
||||
sectionCode: `${this.selected.code}`
|
||||
}
|
||||
sectionCode: selectType.code
|
||||
},
|
||||
cmdType: CMD.Section.CMD_SECTION_FAULT_UNLOCK
|
||||
};
|
||||
|
||||
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
||||
if (valid) {
|
||||
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||
this.$refs.sectionCmdControl.doShow(operate, this.selected);
|
||||
// this.$refs.sectionCmdControl.doShow(operate, this.selected);
|
||||
}
|
||||
});
|
||||
},
|
||||
@ -299,19 +303,6 @@ export default {
|
||||
},
|
||||
// 设置速度
|
||||
setSpeed() {
|
||||
// let operate = {
|
||||
// start: true,
|
||||
// code: this.selected.code,
|
||||
// type: MapDeviceType.Section.type,
|
||||
// label: MapDeviceType.Section.label,
|
||||
// operation: OperationEvent.Section.setLimitSpeed.menu.operation
|
||||
// };
|
||||
// this.$store.dispatch('training/next', operate).then(({ valid }) => {
|
||||
// if (valid) {
|
||||
// this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||
// this.$refs.speedCmdControl.doShow(operate, this.selected);
|
||||
// }
|
||||
// });
|
||||
const operate = {
|
||||
start: true,
|
||||
code: this.selected.code,
|
||||
|
@ -218,6 +218,13 @@ export default {
|
||||
}
|
||||
case OperationEvent.Signal.reopenSignal.button.operation: {
|
||||
// 信号重开
|
||||
if (selectType.greenOpen) {
|
||||
this.$refs.noticeInfo.doShow({}, `信号机[${selectType.name}(${selectType.code})]已开启,无需重开信号机`);
|
||||
} else {
|
||||
// 开放进路信号机因故关闭
|
||||
this.reopenSignalByRoute(selectType);
|
||||
// 开放非进路信号机因故关闭
|
||||
}
|
||||
break;
|
||||
}
|
||||
case OperationEvent.Signal.guide.button.operation: {
|
||||
@ -335,6 +342,27 @@ export default {
|
||||
}
|
||||
});
|
||||
},
|
||||
|
||||
// 现地信号重开操作
|
||||
reopenSignalByRoute(selectType) {
|
||||
const operate = {
|
||||
start: true,
|
||||
code: this.selected.code,
|
||||
operation: OperationEvent.Signal.reopenSignal.menu.operation,
|
||||
param: {
|
||||
signalCode: selectType.code
|
||||
},
|
||||
cmdType: CMD.Signal.CMD_SIGNAL_REOPEN_SIGNAL
|
||||
};
|
||||
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
||||
if (valid) {
|
||||
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||
}
|
||||
}).catch((error) => {
|
||||
this.$refs.noticeInfo.doShow(operate, error.message);
|
||||
});
|
||||
},
|
||||
|
||||
// 信号重开
|
||||
reopenSignal() {
|
||||
const operate = {
|
||||
|
@ -306,42 +306,25 @@ export default {
|
||||
}
|
||||
});
|
||||
},
|
||||
// 道岔故障解锁
|
||||
fault() {
|
||||
const operate = {
|
||||
start: true,
|
||||
code: this.selected.code,
|
||||
operation: OperationEvent.Switch.fault.menu.operation,
|
||||
param: {
|
||||
switchCode: `${this.selected.code}`
|
||||
}
|
||||
};
|
||||
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
||||
if (valid) {
|
||||
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||
this.$refs.switchCmdControl.doShow(operate, this.selected);
|
||||
}
|
||||
});
|
||||
},
|
||||
// 道岔取消速度
|
||||
cancelSpeed() {
|
||||
const operate = {
|
||||
start: true,
|
||||
send: true,
|
||||
code: this.selected.code,
|
||||
operation: OperationEvent.Switch.cancelSpeed.menu.operation,
|
||||
param: {
|
||||
switchCode: `${this.selected.code}`
|
||||
}
|
||||
};
|
||||
this.$store.dispatch('training/nextNew', operate).then(({ valid, response }) => {
|
||||
if (valid) {
|
||||
const tempData = response.data;
|
||||
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||
this.$refs.speedCmdControl.doShow(operate, this.selected, tempData);
|
||||
}
|
||||
});
|
||||
},
|
||||
// cancelSpeed() {
|
||||
// const operate = {
|
||||
// start: true,
|
||||
// send: true,
|
||||
// code: this.selected.code,
|
||||
// operation: OperationEvent.Switch.cancelSpeed.menu.operation,
|
||||
// param: {
|
||||
// switchCode: `${this.selected.code}`
|
||||
// }
|
||||
// };
|
||||
// this.$store.dispatch('training/nextNew', operate).then(({ valid, response }) => {
|
||||
// if (valid) {
|
||||
// const tempData = response.data;
|
||||
// this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||
// this.$refs.speedCmdControl.doShow(operate, this.selected, tempData);
|
||||
// }
|
||||
// });
|
||||
// },
|
||||
|
||||
// 区段切除
|
||||
split() {
|
||||
|
Loading…
Reference in New Issue
Block a user