From 2e44c6942914028ed624c23220c88b4aed97a7cc Mon Sep 17 00:00:00 2001 From: fan <18706759286@163.com> Date: Fri, 12 Jun 2020 14:34:18 +0800 Subject: [PATCH] =?UTF-8?q?=E8=80=81=E7=89=88=E6=9C=AC=E7=A6=8F=E5=B7=9E?= =?UTF-8?q?=E5=88=97=E8=BD=A6=E7=9B=AE=E7=9A=84=E5=9C=B0=E7=A0=81=E8=B0=83?= =?UTF-8?q?=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/jmapNew/config/skinCode/ningbo_01.js | 12 ++++++- .../components/menus/dialog/standControl.vue | 32 +++++++------------ .../theme/fuzhou_01/menus/menuSection.vue | 17 +++------- 3 files changed, 27 insertions(+), 34 deletions(-) diff --git a/src/jmapNew/config/skinCode/ningbo_01.js b/src/jmapNew/config/skinCode/ningbo_01.js index 6a4301278..3c2fadabf 100644 --- a/src/jmapNew/config/skinCode/ningbo_01.js +++ b/src/jmapNew/config/skinCode/ningbo_01.js @@ -534,7 +534,17 @@ class SkinCode extends defaultStyle { fontFamily: 'consolas', trainBodyLineWidth: 1, // 车身line宽 changeTrainWidth: false, // 是否根据车身上车组号、服务号、车次号、目的地码显示情况改变列车长度 - specialTrainType: [], // 特殊列车类型需设置显示格式 + specialTrainType: [ + { + type: 'MANUAL', + serviceNumber: '', + nameFormat: 'groupNumber:targetCode' + }, + { + type: 'HEAD', + nameFormat: 'groupNumber:targetCode' + } + ], // 特殊列车类型需设置显示格式 lrPadding: 4, // 两边间隔 upPadding: 4, // 上边距离 trainSidelineColor: '#ABFE9B', diff --git a/src/jmapNew/theme/components/menus/dialog/standControl.vue b/src/jmapNew/theme/components/menus/dialog/standControl.vue index c8577b263..55985dff9 100644 --- a/src/jmapNew/theme/components/menus/dialog/standControl.vue +++ b/src/jmapNew/theme/components/menus/dialog/standControl.vue @@ -130,6 +130,7 @@ import { OperationEvent } from '@/scripts/cmdPlugin/OperationHandler'; import OperationHandler from '@/scripts/cmdPlugin/OperationHandler'; import NoticeInfo from '../../menus/childDialog/childDialog/noticeInfo'; import {menuOperate, commitOperate} from '../../utils/menuOperate'; +import { mapGetters } from 'vuex'; export default { name: 'StandDetainTrain', @@ -161,6 +162,9 @@ export default { }; }, computed: { + ...mapGetters('map', [ + 'mapConfig' + ]), show() { return this.dialogShow && !this.$store.state.menuOperation.break; }, @@ -213,7 +217,7 @@ export default { } } this.radio = '2'; - if (this.selected.right) { // 判断站台行驶方向 + if ((this.selected.right && this.mapConfig.upDirection === 'right') || (!this.selected.right && this.mapConfig.upDirection === 'left')) { // 判断站台行驶方向 this.radio = '1'; } @@ -237,7 +241,7 @@ export default { this.radio1 = '2'; } else if (this.operation == OperationEvent.StationStand.earlyDeparture.menu.operation) { this.earlyDepar = true; - if (!this.selected.right) { + if ((!this.selected.right && this.mapConfig.upDirection === 'right') || (this.selected.right && this.mapConfig.upDirection === 'left')) { this.radio2 = '2'; } else { this.radio2 = '1'; @@ -246,14 +250,14 @@ export default { this.AutomaticBuckle = true; this.autoRadio1 = '1'; this.autoRadio = '1'; - if (!this.selected.right) { + if ((!this.selected.right && this.mapConfig.upDirection === 'right') || (this.selected.right && this.mapConfig.upDirection === 'left')) { this.autoRadio = '2'; } } else if (this.operation == OperationEvent.StationStand.cancelDetainTrainAuto.menu.operation) { this.AutomaticBuckle = true; this.autoRadio1 = '2'; this.autoRadio = '1'; - if (!this.selected.right) { + if ((!this.selected.right && this.mapConfig.upDirection === 'right') || (this.selected.right && this.mapConfig.upDirection === 'left')) { this.autoRadio = '2'; } } @@ -303,30 +307,18 @@ export default { } }, setDetainTrainAuto() { // 区间自动扣车 - this.sendCommand(menuOperate.StationStand.setDetainTrainAuto, { - leftDirection: this.autoRadio == '2', // 1 上行 2 下行 - rightDirection: this.autoRadio == '1' - }); + this.sendCommand(menuOperate.StationStand.setDetainTrainAuto); }, cancelDetainTrainAuto() { // 取消区间自动扣车 - this.sendCommand(menuOperate.StationStand.cancelDetainTrainAuto, { - leftDirection: this.autoRadio == '2', // 1 上行 2 下行 - rightDirection: this.autoRadio == '1' - }); + this.sendCommand(menuOperate.StationStand.cancelDetainTrainAuto); }, // 设置扣车 setDetainTrain() { - this.sendCommand(menuOperate.StationStand.setDetainTrain, { - leftDirection: this.radio == '2', // 1 上行 2 下行 - rightDirection: this.radio == '1' - }); + this.sendCommand(menuOperate.StationStand.setDetainTrain); }, // 取消扣车 cancelDetainTrain() { - this.sendCommand(menuOperate.StationStand.cancelDetainTrain, { - leftDirection: this.radio == '2', // 1 上行 2 下行 - rightDirection: this.radio == '1' - }); + this.sendCommand(menuOperate.StationStand.cancelDetainTrain); }, // 提前发车 earlyDeparture() { diff --git a/src/jmapNew/theme/fuzhou_01/menus/menuSection.vue b/src/jmapNew/theme/fuzhou_01/menus/menuSection.vue index 7824937d6..91683e07d 100644 --- a/src/jmapNew/theme/fuzhou_01/menus/menuSection.vue +++ b/src/jmapNew/theme/fuzhou_01/menus/menuSection.vue @@ -230,18 +230,9 @@ export default { }, // 故障解锁 fault() { - const step = { - start: true, - code: `${this.selected.code}`, - operation: OperationEvent.Section.fault.menu.operation, - param: { - Section_Code: `${this.selected.code}` - } - }; - this.$store.dispatch('training/next', step).then(({ valid }) => { + commitOperate(menuOperate.Section.fault, {sectionCode: this.selected.code}, 0).then(({valid, operate}) => { if (valid) { - this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); - this.$refs.sectionCmdControl.doShow(step, this.selected); + this.$refs.sectionCmdControl.doShow(operate, this.selected); } }); }, @@ -252,7 +243,7 @@ export default { code: `${this.selected.code}`, operation: OperationEvent.Section.split.menu.operation, param: { - Section_Code: `${this.selected.code}` + sectionCode: `${this.selected.code}` } }; this.$store.dispatch('training/next', step).then(({ valid }) => { @@ -269,7 +260,7 @@ export default { code: `${this.selected.code}`, operation: OperationEvent.Section.active.menu.operation, param: { - Section_Code: `${this.selected.code}` + sectionCode: `${this.selected.code}` } }; this.$store.dispatch('training/next', step).then(({ valid }) => {