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() {
|
doClose() {
|
||||||
this.loading = false;
|
this.loading = false;
|
||||||
this.dialogShow = false;
|
this.dialogShow = false;
|
||||||
this.sure && (this.currentSelect = null);
|
this.currentSelect = null;
|
||||||
this.sure && this.$refs.table.setCurrentRow();
|
this.$refs.table.setCurrentRow();
|
||||||
this.sure && this.$root.$emit('iniCacheMap', this.cmdType.value,
|
this.sure && this.$root.$emit('iniCacheMap', this.cmdType.value,
|
||||||
Object.fromEntries(Object.entries(this.getCacheMap()).filter(el => el[1].done == 'done'))
|
Object.fromEntries(Object.entries(this.getCacheMap()).filter(el => el[1].done == 'done'))
|
||||||
);
|
);
|
||||||
|
@ -3,6 +3,7 @@
|
|||||||
<el-row>
|
<el-row>
|
||||||
<el-col :span="18">
|
<el-col :span="18">
|
||||||
<el-table
|
<el-table
|
||||||
|
:id="domIdChoose"
|
||||||
ref="table"
|
ref="table"
|
||||||
:data="switchList"
|
:data="switchList"
|
||||||
highlight-current-row
|
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-button :id="domIdConfirm" type="primary" :disabled="!selectedSwitchCode" :loading="loading" :selected="true" @click="commit(true)">确定(O)</el-button>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="4" :offset="2">
|
<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>
|
||||||
<el-col :span="4" :offset="2">
|
<el-col :span="4" :offset="2">
|
||||||
<el-button :id="domIdClose" @click="cancel">关闭(C)</el-button>
|
<el-button :id="domIdClose" @click="cancel">关闭(C)</el-button>
|
||||||
@ -103,10 +104,13 @@ export default {
|
|||||||
return this.dialogShow ? OperationEvent.Command.cancel.menu.domId : '';
|
return this.dialogShow ? OperationEvent.Command.cancel.menu.domId : '';
|
||||||
},
|
},
|
||||||
domIdChoose() {
|
domIdChoose() {
|
||||||
return this.dialogShow ? OperationEvent.Signal.arrangementRoute.choose.domId : '';
|
return this.dialogShow ? OperationEvent.Switch.turnout.menu.domId : '';
|
||||||
},
|
},
|
||||||
domIdConfirm() {
|
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() {
|
title() {
|
||||||
return '道岔命令';
|
return '道岔命令';
|
||||||
@ -193,17 +197,17 @@ export default {
|
|||||||
handleCurrentChange(val) {
|
handleCurrentChange(val) {
|
||||||
if (!val) { return; }
|
if (!val) { return; }
|
||||||
commitOperate(menuOperate.Switch.turnout, {code:val.code}).then(({valid, operate})=>{
|
commitOperate(menuOperate.Switch.turnout, {code:val.code}).then(({valid, operate})=>{
|
||||||
if (valid) {
|
// if (valid) {
|
||||||
this.position = '';
|
this.position = '';
|
||||||
const switchModel = this.$store.getters['map/getDeviceByCode'](val.code);
|
const switchModel = this.$store.getters['map/getDeviceByCode'](val.code);
|
||||||
this.selectedSwitchCode = val.code;
|
this.selectedSwitchCode = val.code;
|
||||||
this.selectedSwitch = switchModel;
|
this.selectedSwitch = switchModel;
|
||||||
// this.mode = elem.auto ? 'artificial' : 'auto';
|
// this.mode = elem.auto ? 'artificial' : 'auto';
|
||||||
// if (!elem.auto) {
|
// if (!elem.auto) {
|
||||||
// if (elem.normalPosition) { this.position = 'reverse'; }
|
// if (elem.normalPosition) { this.position = 'reverse'; }
|
||||||
// if (elem.reversePosition) { this.position = 'normal'; }
|
// if (elem.reversePosition) { this.position = 'normal'; }
|
||||||
// }
|
// }
|
||||||
}
|
// }
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
getSwitchPosition(code) {
|
getSwitchPosition(code) {
|
||||||
|
@ -145,6 +145,12 @@ export default {
|
|||||||
watch: {
|
watch: {
|
||||||
'$store.state.menuOperation.menuCount': function (val) {
|
'$store.state.menuOperation.menuCount': function (val) {
|
||||||
if (this.$store.getters['menuOperation/checkDialogIsOpen'](DeviceMenu.Switch) && !this.buttonOperation) {
|
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);
|
this.doShow(this.$store.state.menuOperation.menuPosition);
|
||||||
} else {
|
} else {
|
||||||
this.doClose();
|
this.doClose();
|
||||||
|
Loading…
Reference in New Issue
Block a user