大铁线路 现地 上电解锁代码调整
This commit is contained in:
parent
229528d1ff
commit
cd3c6e586a
@ -86,7 +86,8 @@
|
||||
<center><b>S引导总锁</b></center>
|
||||
</span>
|
||||
</button>
|
||||
<button :id="Station.powerUnLock.button.domId" class="button_box" :style="{width: width+'px', backgroundColor:buttonUpColor}" @click="powerOnUnlock()">
|
||||
<!-- powerOnUnlock -->
|
||||
<button :id="Station.powerUnLock.button.domId" class="button_box" :style="{width: width+'px', backgroundColor:buttonUpColor}" @click="buttonDown(Station.powerUnLock.button.operation,['Station'])">
|
||||
<!--<span style="color:black">-->
|
||||
<span style="color:#800000">
|
||||
<center><b>上电解锁</b></center>
|
||||
@ -334,6 +335,9 @@ export default {
|
||||
} else if (operate.operationPre === this.Switch.guideLock.rightButton.operation || operate.operation === this.Switch.guideLock.rightButton.operation) {
|
||||
this.guideLockRightFlag = !this.guideLockRightFlag;
|
||||
}
|
||||
if (operate.operationPre == this.Station.powerUnLock.button.operation) {
|
||||
this.clearOperate();
|
||||
}
|
||||
// debugger;
|
||||
// this.$store.dispatch('menuOperation/setButtonOperation', operate.operation); // 按钮菜单是否被按下
|
||||
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||
@ -366,26 +370,38 @@ export default {
|
||||
}
|
||||
}
|
||||
},
|
||||
// 上电解锁 大铁线路
|
||||
powerOnUnlock() {
|
||||
const operate = {
|
||||
over:true,
|
||||
operation:this.Station.powerUnLock.button.operation,
|
||||
cmdType:CMD.Station.CMD_STATION_POWER_ON_UNLOCK,
|
||||
code:this.$store.state.map.showCentralizedStationCode,
|
||||
param:{stationCode: this.$store.state.map.showCentralizedStationCode}
|
||||
};
|
||||
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
||||
if (valid) {
|
||||
this.clearOperate();
|
||||
} else {
|
||||
this.$refs.noticeInfo.doShow();
|
||||
}
|
||||
}).catch((error) => {
|
||||
console.error(error);
|
||||
this.$refs.noticeInfo.doShow();
|
||||
});
|
||||
},
|
||||
// // 上电解锁 大铁线路
|
||||
// handelPowerUnLock(model) {
|
||||
// debugger;
|
||||
// const operate = {
|
||||
// over: true,
|
||||
// code: model.code,
|
||||
// operation: this.$store.state.menuOperation.buttonOperation,
|
||||
// userOperationType: 'leftClick',
|
||||
// cmdType: CMD.Station.CMD_STATION_POWER_ON_UNLOCK,
|
||||
// param:{stationCode: this.$store.state.map.showCentralizedStationCode}
|
||||
// };
|
||||
// this.sendCommand(operate);
|
||||
// },
|
||||
// powerOnUnlock() {
|
||||
// const operate = {
|
||||
// over:true,
|
||||
// operation:this.Station.powerUnLock.button.operation,
|
||||
// cmdType:CMD.Station.CMD_STATION_POWER_ON_UNLOCK,
|
||||
// code:this.$store.state.map.showCentralizedStationCode,
|
||||
// param:{stationCode: this.$store.state.map.showCentralizedStationCode}
|
||||
// };
|
||||
// this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
||||
// if (valid) {
|
||||
// this.clearOperate();
|
||||
// } else {
|
||||
// this.$refs.noticeInfo.doShow();
|
||||
// }
|
||||
// }).catch((error) => {
|
||||
// console.error(error);
|
||||
// this.$refs.noticeInfo.doShow();
|
||||
// });
|
||||
// },
|
||||
// 分路不良
|
||||
handelDefectiveShunting(model) {
|
||||
// CMD.Section.CMD_SECTION_DEFECTIVE_SHUNTING;
|
||||
@ -444,13 +460,17 @@ export default {
|
||||
userOperationType: 'leftClick'
|
||||
};
|
||||
// 以下 会弹出密码框 (总人解,区故解) 铅封按钮
|
||||
const operationList = [this.Signal.humanTrainRoute.button.operation, this.Section.fault.button.operation, this.Section.defectiveShunting.button.operation,
|
||||
const operationList = [this.Signal.humanTrainRoute.button.operation,
|
||||
this.Section.fault.button.operation,
|
||||
this.Section.defectiveShunting.button.operation,
|
||||
this.Station.powerUnLock.button.operation,
|
||||
this.Signal.signalTurnOff.menuButton.operation];
|
||||
const operationMap = {
|
||||
[this.Signal.humanTrainRoute.button.operation]:'总人解',
|
||||
[this.Section.fault.button.operation]:'区故解',
|
||||
[this.Section.defectiveShunting.button.operation]:'分路不良',
|
||||
[this.Signal.signalTurnOff.menuButton.operation]:'灭灯'
|
||||
[this.Signal.signalTurnOff.menuButton.operation]:'灭灯',
|
||||
[this.Station.powerUnLock.button.operation]:'上电解锁'
|
||||
};
|
||||
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
||||
if (valid) {
|
||||
@ -461,6 +481,10 @@ export default {
|
||||
// 判断是否需要 弹窗密码框
|
||||
if (operationList.includes(operation)) {
|
||||
operate['operateNext'] = this.Command.close.password.operation;
|
||||
if (operation == this.Station.powerUnLock.button.operation) {
|
||||
operate.nextCmdType = CMD.Station.CMD_STATION_POWER_ON_UNLOCK;
|
||||
operate.param = {stationCode: this.$store.state.map.showCentralizedStationCode};
|
||||
}
|
||||
this.$refs.password.doShow(operate, operationMap[operation]);
|
||||
}
|
||||
this.timeNode = this.$store.state.socket.simulationTimeSync;
|
||||
|
Loading…
Reference in New Issue
Block a user