福州三号线车辆端 信号机 添加操作指令
This commit is contained in:
parent
c699a09431
commit
67bf5babb0
@ -26,7 +26,7 @@
|
||||
<button :id="Signal.unlock.button.domId" class="button_box" :style="{width: width+'px', backgroundColor:buttonUpColor}" @click="buttonDown(Signal.unlock.button.operation)">
|
||||
<span class="buttonColor">钮解</span>
|
||||
</button>
|
||||
<button :id="Command.cancel.clearMbm.domId" class="button_box" :style="{width: width+'px', backgroundColor:buttonUpColor}" @click="buttonDown(Command.cancel.clearMbm.operation)">
|
||||
<button :id="Signal.cancelTrainRoute.button.domId" class="button_box" :style="{width: width+'px', backgroundColor:buttonUpColor}" @click="buttonDown(Signal.cancelTrainRoute.button.operation)">
|
||||
<span class="buttonColor">取消</span>
|
||||
</button>
|
||||
<button :id="Section.fault.button.domId" class="button_box" :style="{width: width+'px', backgroundColor:buttonUpColor,color:'#DA2D29'}" @click="buttonDown(Section.fault.button.operation)">
|
||||
@ -69,7 +69,7 @@ import PasswordBox from '@/jmapNew/theme/components/menus/childDialog/passwordIn
|
||||
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
|
||||
import OperationHandler from '@/scripts/cmdPlugin/OperationHandler';
|
||||
import Handler from '@/scripts/cmdPlugin/Handler';
|
||||
import CMD from '@/scripts/cmdPlugin/CommandEnum';
|
||||
// import CMD from '@/scripts/cmdPlugin/CommandEnum';
|
||||
export default {
|
||||
name:'MenuDeplotButton',
|
||||
components: {
|
||||
@ -186,7 +186,7 @@ export default {
|
||||
buttonDown(operation) {
|
||||
// 清空当前的选择的设备
|
||||
this.deviceList = [];
|
||||
if (operation != this.Command.cancel.clearMbm.operation) {
|
||||
// if (operation != this.Command.cancel.clearMbm.operation) {
|
||||
const operate = {
|
||||
operation: operation
|
||||
};
|
||||
@ -212,20 +212,19 @@ export default {
|
||||
this.$store.dispatch('training/emitTipFresh');
|
||||
}
|
||||
});
|
||||
|
||||
} else {
|
||||
const operate = {
|
||||
start: true,
|
||||
operation: operation
|
||||
};
|
||||
this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
||||
if (valid) {
|
||||
this.$store.dispatch('menuOperation/setButtonOperation', null);
|
||||
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||
Handler.clear(); // 清空操作组
|
||||
}
|
||||
});
|
||||
}
|
||||
// } else {
|
||||
// const operate = {
|
||||
// start: true,
|
||||
// operation: operation
|
||||
// };
|
||||
// this.$store.dispatch('training/nextNew', operate).then(({ valid }) => {
|
||||
// if (valid) {
|
||||
// this.$store.dispatch('menuOperation/setButtonOperation', null);
|
||||
// this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
|
||||
// Handler.clear(); // 清空操作组
|
||||
// }
|
||||
// });
|
||||
// }
|
||||
}
|
||||
}
|
||||
};
|
||||
|
@ -247,6 +247,7 @@ export default {
|
||||
},
|
||||
operationHandler(buttonOperation, selectType) {
|
||||
switch (buttonOperation) {
|
||||
// 信号机封锁
|
||||
case OperationEvent.Signal.lock.button.operation: {
|
||||
commitOperate(menuOperate.Signal.lock, {signalCode: selectType.code}, 3).then(({valid, operate}) => {
|
||||
if (valid) {
|
||||
@ -260,7 +261,8 @@ export default {
|
||||
});
|
||||
break;
|
||||
}
|
||||
case OperationEvent.Signal.lock.unlock.operation: {
|
||||
// 信号机解封
|
||||
case OperationEvent.Signal.unlock.button.operation: {
|
||||
// this.unlock(selectType);
|
||||
commitOperate(menuOperate.Signal.unlock, {signalCode: selectType.code}, 3).then(({valid, operate}) => {
|
||||
if (valid) {
|
||||
@ -274,6 +276,22 @@ export default {
|
||||
});
|
||||
break;
|
||||
}
|
||||
// 取消进路
|
||||
case OperationEvent.Signal.cancelTrainRoute.button.operation: {
|
||||
commitOperate(menuOperate.Signal.cancelTrainRoute, {signalCode: selectType.code}, 3).then(({valid, operate}) => {
|
||||
if (valid) {
|
||||
// this.$refs.routeLock.doShow(operate, this.selected);
|
||||
} else {
|
||||
this.$refs.noticeInfo.doShow();
|
||||
}
|
||||
}).catch(error=>{
|
||||
console.error(error);
|
||||
this.$refs.noticeInfo.doShow();
|
||||
});
|
||||
break;
|
||||
}
|
||||
// 人解进路
|
||||
// 排列进路
|
||||
default: {
|
||||
break;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user