Merge branch 'test_dispaly' of https://git.code.tencent.com/lian-cbtc/jl-client into test_dispaly1
This commit is contained in:
commit
fdb244d802
@ -193,8 +193,8 @@ export default {
|
||||
doClose() {
|
||||
this.loading = false;
|
||||
this.dialogShow = false;
|
||||
this.sure && (this.currentSelect = null);
|
||||
this.sure && this.$refs.table.setCurrentRow();
|
||||
this.currentSelect = null;
|
||||
this.$refs.table.setCurrentRow();
|
||||
this.sure && this.$root.$emit('iniCacheMap', this.cmdType.value,
|
||||
Object.fromEntries(Object.entries(this.getCacheMap()).filter(el => el[1].done == 'done'))
|
||||
);
|
||||
|
@ -3,6 +3,7 @@
|
||||
<el-row>
|
||||
<el-col :span="18">
|
||||
<el-table
|
||||
:id="domIdChoose"
|
||||
ref="table"
|
||||
:data="switchList"
|
||||
highlight-current-row
|
||||
@ -52,7 +53,7 @@
|
||||
<el-button :id="domIdConfirm" type="primary" :disabled="!selectedSwitchCode" :loading="loading" :selected="true" @click="commit(true)">确定(O)</el-button>
|
||||
</el-col>
|
||||
<el-col :span="4" :offset="2">
|
||||
<el-button :id="domIdConfirm" type="primary" :disabled="!selectedSwitchCode" :loading="loading" :selected="true" @click="commit(false)">应用(A)</el-button>
|
||||
<el-button :id="domIdApply" type="primary" :disabled="!selectedSwitchCode" :loading="loading" :selected="true" @click="commit(false)">应用(A)</el-button>
|
||||
</el-col>
|
||||
<el-col :span="4" :offset="2">
|
||||
<el-button :id="domIdClose" @click="cancel">关闭(C)</el-button>
|
||||
@ -103,10 +104,13 @@ export default {
|
||||
return this.dialogShow ? OperationEvent.Command.cancel.menu.domId : '';
|
||||
},
|
||||
domIdChoose() {
|
||||
return this.dialogShow ? OperationEvent.Signal.arrangementRoute.choose.domId : '';
|
||||
return this.dialogShow ? OperationEvent.Switch.turnout.menu.domId : '';
|
||||
},
|
||||
domIdConfirm() {
|
||||
return this.dialogShow ? OperationEvent.Signal.arrangementRoute.menu.domId : '';
|
||||
return this.dialogShow ? OperationEvent.Command.common.confirm.domId : '';
|
||||
},
|
||||
domIdApply() {
|
||||
return this.dialogShow ? OperationEvent.Command.common.apply.domId : '';
|
||||
},
|
||||
title() {
|
||||
return '道岔命令';
|
||||
@ -193,17 +197,17 @@ export default {
|
||||
handleCurrentChange(val) {
|
||||
if (!val) { return; }
|
||||
commitOperate(menuOperate.Switch.turnout, {code:val.code}).then(({valid, operate})=>{
|
||||
if (valid) {
|
||||
this.position = '';
|
||||
const switchModel = this.$store.getters['map/getDeviceByCode'](val.code);
|
||||
this.selectedSwitchCode = val.code;
|
||||
this.selectedSwitch = switchModel;
|
||||
// this.mode = elem.auto ? 'artificial' : 'auto';
|
||||
// if (!elem.auto) {
|
||||
// if (elem.normalPosition) { this.position = 'reverse'; }
|
||||
// if (elem.reversePosition) { this.position = 'normal'; }
|
||||
// }
|
||||
}
|
||||
// if (valid) {
|
||||
this.position = '';
|
||||
const switchModel = this.$store.getters['map/getDeviceByCode'](val.code);
|
||||
this.selectedSwitchCode = val.code;
|
||||
this.selectedSwitch = switchModel;
|
||||
// this.mode = elem.auto ? 'artificial' : 'auto';
|
||||
// if (!elem.auto) {
|
||||
// if (elem.normalPosition) { this.position = 'reverse'; }
|
||||
// if (elem.reversePosition) { this.position = 'normal'; }
|
||||
// }
|
||||
// }
|
||||
});
|
||||
},
|
||||
getSwitchPosition(code) {
|
||||
|
@ -145,6 +145,12 @@ export default {
|
||||
watch: {
|
||||
'$store.state.menuOperation.menuCount': function (val) {
|
||||
if (this.$store.getters['menuOperation/checkDialogIsOpen'](DeviceMenu.Switch) && !this.buttonOperation) {
|
||||
const operate = {
|
||||
code: `${this.selected.code}`,
|
||||
userOperationType: 'rightClick',
|
||||
operation: OperationEvent.Command.commandRight.right.operation
|
||||
};
|
||||
this.$store.dispatch('trainingNew/next', operate);
|
||||
this.doShow(this.$store.state.menuOperation.menuPosition);
|
||||
} else {
|
||||
this.doClose();
|
||||
|
Loading…
Reference in New Issue
Block a user