代码调整

This commit is contained in:
joylink_cuiweidong 2022-12-09 16:40:32 +08:00
parent ce983bc448
commit 5eeb655b39
3 changed files with 364 additions and 4 deletions

View File

@ -1,15 +1,22 @@
<template>
<div id="menuBarChengdu03">
<div id="menuBarChengdu3">
<menu-bar ref="menuBar" :menu-normal="menuNormal" style="width:100%" />
<help-about ref="helpAbout" />
<set-limit-speed ref="setLimitSpeed" />
</div>
</template>
<script>
import MenuBar from '@/jmapNew/theme/components/menus/menuBarNew';
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
import HelpAbout from './menuDialog/helpAbout';
import SetLimitSpeed from './menuDialog/setLimitSpeed';
export default {
name: 'DispatchWorkMenuBar',
components: {
MenuBar
MenuBar,
HelpAbout,
SetLimitSpeed
},
data() {
return {
@ -362,3 +369,11 @@ export default {
}
};
</script>
<style rel="stylesheet/scss" lang="scss">
#menuBarChengdu3{
line-height:30px;
}
#menuBarChengdu3 #menuBar .menu-li-block .label{
padding: 0px 30px 0px 5px !important;
}
</style>

View File

@ -1,18 +1,21 @@
<template>
<div class="menus" :style="{width: width + 'px'}">
<menu-bar ref="menuBar" :selected="selected" />
<menu-button ref="menuButton" />
<menu-train ref="menuTrain" :selected="selected" :work="'dispatchWork'" />
<menu-train ref="menuTrain" :selected="selected" :work="'localWork'" />
</div>
</template>
<script>
import { mapGetters } from 'vuex';
import MenuTrain from './menuTrain';
import MenuButton from './menuButton';
import MenuBar from './localWorkMenuBar';
export default {
name: 'LocalWorkMenu',
components: {
MenuTrain,
MenuButton
MenuButton,
MenuBar
},
props: {
selected: {

View File

@ -0,0 +1,342 @@
<template>
<div id="menuBarChengdu3">
<menu-bar ref="menuBar" :menu-normal="menuNormal" style="width:100%" />
<help-about ref="helpAbout" />
<set-limit-speed ref="setLimitSpeed" />
</div>
</template>
<script>
import MenuBar from '@/jmapNew/theme/components/menus/menuBarNew';
import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler';
import HelpAbout from './menuDialog/helpAbout';
import SetLimitSpeed from './menuDialog/setLimitSpeed';
export default {
name: 'LocalWorkMenuBar',
components: {
MenuBar,
HelpAbout,
SetLimitSpeed
},
data() {
return {
menuNormal:[
{
title: '系统',
// operate: OperationEvent.Command.mBar.system,
operate: '',
children: [
{
title: '登录',
click: this.undeveloped
},
{
title: '注销',
click: this.undeveloped
},
{
type: 'separator'
},
{
title: '连接主用中心',
click: this.undeveloped
},
{
title: '连接备用中心',
click: this.undeveloped
},
{
type: 'separator'
},
{
title: '退出',
click: this.undeveloped
}
]
},
{
title: '临时限速',
operate: OperationEvent.Command.mBar.limitSpeed,
children: [
{
title: '设置临时限速',
operate: OperationEvent.Section.setLimitSpeed,
click: this.setLimitSpeed
},
{
title: '取消临时限速',
operate: OperationEvent.Section.cancelSpeed,
click: this.cancleLimitSpeed
}
]
},
{
title: '查看',
// operate: OperationEvent.Command.mBar.check,
operate: '',
children: [
{
title: '运行图',
click: this.undeveloped
},
{
title: '报告分析',
click: this.undeveloped
},
{
type: 'separator'
},
{
title: '视图',
click: this.undeveloped,
operate: '',
children: [{
title: '报警',
click: this.undeveloped
},
{
title: '列车运行信息',
click: this.undeveloped
},
{
title: '设备状态',
click: this.undeveloped
},
{
title: '列车详细信息',
click: this.undeveloped
},
{
title: '站台详细信息',
click: this.undeveloped
}]
},
{
title: '终端站发车列表',
click: this.undeveloped
},
{
title: '详细设备状态',
click: this.undeveloped
},
{
title: '查找列车',
click: this.undeveloped
},
{
type: 'separator'
},
{
title: '显示目的地号',
click: this.undeveloped
},
{
title: '显示轨道名',
click: this.undeveloped
},
{
title: '显示道岔名',
click: this.undeveloped
},
{
title: '显示信号机名',
click: this.undeveloped
},
{
title: '显示车次窗位置',
click: this.undeveloped
},
{
type: 'separator'
},
{
title: '显示车次号',
click: this.undeveloped
},
{
title: '显示车组号',
click: this.undeveloped
},
{
type: 'separator'
},
{
title: '全屏',
click: this.undeveloped
},
{
title: '放大',
click: this.undeveloped
},
{
title: '缩小',
click: this.undeveloped
},
{
title: '恢复',
click: this.undeveloped
}
]
},
{
title: '显示',
// operate: OperationEvent.Command.mBar.view,
operate: '',
hide: true,
children: [
{
title: '设置列车识别号显示',
click: this.setTrainIdDisplay,
operate: OperationEvent.Command.view.setTrainIdDisplay
},
{
title: '设置名称显示',
click: this.setNameDisplay,
operate: OperationEvent.Command.view.setNameDisplay
},
{
title: '设置设备显示',
click: this.setDeviceDisplay,
operate: OperationEvent.Command.view.setDeviceDisplay
}
]
},
{
title: 'ATS终端操作',
operate: '',
children: [
{
title: '当天运行车计划',
click: this.undeveloped
},
{
title: '出入库预告',
click: this.undeveloped
}
]
},
{
title: '计划车操作',
operate: '',
children: [
{
title: '添加计划车',
click: this.undeveloped
},
{
title: '平移计划车',
click: this.undeveloped
},
{
title: '删除计划车',
click: this.undeveloped
}
]
},
{
title: '批处理命令',
operate: '',
children: [
{
title: '全线扣车',
click: this.undeveloped
},
{
title: '取消全线扣车',
click: this.undeveloped
},
{
title: '取消上行全线扣车',
click: this.undeveloped
},
{
title: '取消下行全线扣车',
click: this.undeveloped
}
]
},
{
title: '信息管理',
operate: '',
children: [
{
title: '调度日志',
click: this.undeveloped
},
{
title: '调度留言提醒',
click: this.undeveloped
},
{
title: '报警设置',
click: this.undeveloped
}
]
},
{
title: '帮助',
operate: '',
children: [
{
title: '关于ITS GPC 工作站',
click: this.about,
operate: OperationEvent.Command.help.about
}
]
}
]
};
},
methods:{
undeveloped() {
this.$refs.menuBar.doClose();
this.$alert('实现中......', '提示', {
confirmButtonText: '确定',
callback: action => {
}
});
},
setLimitSpeed(order) {
const operate = {
operation: order.operate
};
this.$store.dispatch('trainingNew/next', operate).then(({ valid }) => {
if (valid) {
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.setLimitSpeed.doShow(operate, true);
}
});
},
cancleLimitSpeed(order) {
const operate = {
operation: order.operate
};
this.$store.dispatch('trainingNew/next', operate).then(({ valid }) => {
if (valid) {
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.setLimitSpeed.doShow(operate, false);
}
});
},
//
about(order) {
const operate = {
operation: order.operate
};
this.$store.dispatch('trainingNew/next', operate).then(({ valid }) => {
if (valid) {
this.$store.dispatch('menuOperation/handleBreakFlag', { break: true });
this.$refs.helpAbout.doShow(operate);
}
});
}
}
};
</script>
<style rel="stylesheet/scss" lang="scss">
#menuBarChengdu3{
line-height:30px;
}
#menuBarChengdu3 #menuBar .menu-li-block .label{
padding: 0px 30px 0px 5px !important;
}
</style>