From 90d80897c63179311d1a014843b17069f42c2b9e Mon Sep 17 00:00:00 2001 From: fan <18706759286@163.com> Date: Thu, 4 Jun 2020 16:44:04 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BD=9B=E5=B1=B1=E6=8E=A7=E5=88=B6=E6=A8=A1?= =?UTF-8?q?=E5=BC=8F=E8=BD=AC=E6=8D=A2=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../menus/menuDialog/stationControl.vue | 43 +++-- .../foshan_01/menus/passiveDialog/alarm.vue | 26 +-- .../foshan_01/menus/passiveDialog/control.vue | 168 ++++++++++-------- 3 files changed, 130 insertions(+), 107 deletions(-) diff --git a/src/jmapNew/theme/foshan_01/menus/menuDialog/stationControl.vue b/src/jmapNew/theme/foshan_01/menus/menuDialog/stationControl.vue index c27df4e78..797f4ad94 100644 --- a/src/jmapNew/theme/foshan_01/menus/menuDialog/stationControl.vue +++ b/src/jmapNew/theme/foshan_01/menus/menuDialog/stationControl.vue @@ -12,8 +12,9 @@ :close-on-click-modal="false" > 集中站 - - + + + - - - - - - {{ controlProps[item] }} - + + + + + {{ controlProps[item] }} + + + + 设置 退出 @@ -68,9 +71,9 @@ export default { disabledClose: false, disabledCommit: false, controlModeList: [], - stationType: 'Center', formModel: { - stationCode: '' + stationCode: '', + stationType: '' }, controlProps: { 'Emergency': '紧急站控', @@ -81,6 +84,9 @@ export default { stationCode: [ { required: true, message: '请选择集中站', trigger: 'change' }, { validator: validatePass, trigger: 'change' } + ], + stationType: [ + {required: true, message: '请选择控制模式', trigger: 'change'} ] }, centralizedStationList: [] @@ -105,11 +111,11 @@ export default { }, domIdCommit() { if (this.dialogShow) { - if (this.stationType === 'Center') { + if (this.formModel.stationType === 'Center') { return OperationEvent.StationControl.requestCentralControl.menu.domId; - } else if (this.stationType === 'Local') { + } else if (this.formModel.stationType === 'Local') { return OperationEvent.StationControl.requestStationControl.menu.domId; - } else if (this.stationType === 'Emergency') { + } else if (this.formModel.stationType === 'Emergency') { return OperationEvent.StationControl.emergencyStationControl.menu.domId; } } else { @@ -207,13 +213,13 @@ export default { handleCommit() { this.$refs.form.validate((valid) => { if (valid) { - if (this.stationType === 'Center') { + if (this.formModel.stationType === 'Center') { // 请求遥控 this.conterCommit(); - } else if (this.stationType === 'Local') { + } else if (this.formModel.stationType === 'Local') { // 请求站控 this.requestCommit(); - } else if (this.stationType === 'Emergency') { + } else if (this.formModel.stationType === 'Emergency') { // 紧急站控 this.emergencyCommit(); } @@ -231,6 +237,7 @@ export default { if (valid) { this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); this.$refs.twoConfirmation.doShow(operate); + this.doClose(); } else { this.disabledSure = false; } @@ -247,6 +254,7 @@ export default { if (valid) { this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); this.$refs.twoConfirmation.doShow(operate); + this.doClose(); } else { this.disabledSure = false; } @@ -263,6 +271,7 @@ export default { if (valid) { this.$store.dispatch('menuOperation/handleBreakFlag', { break: true }); this.$refs.twoConfirmation.doShow(operate); + this.doClose(); } else { this.disabledSure = false; } diff --git a/src/jmapNew/theme/foshan_01/menus/passiveDialog/alarm.vue b/src/jmapNew/theme/foshan_01/menus/passiveDialog/alarm.vue index bf7d7d40c..dd1b085ae 100644 --- a/src/jmapNew/theme/foshan_01/menus/passiveDialog/alarm.vue +++ b/src/jmapNew/theme/foshan_01/menus/passiveDialog/alarm.vue @@ -125,19 +125,19 @@ export default { }, watch: { '$store.state.socket.msgHead': function (elem) { - if (elem && elem.hasOwnProperty('success')) { - if (elem.success) { - const operate = this.$store.state.training.operate; - const control = this.$store.getters['map/getDeviceByCode'](elem.stationControlCode); - const station = this.$store.getters['map/getDeviceByCode'](control.stationCode); - const newOperate = { - type: operate.type, - name: station.name - }; - - this.doShow(newOperate); - } - } + // if (elem && elem.hasOwnProperty('success')) { + // if (elem.success) { + // const operate = this.$store.state.training.operate; + // const control = this.$store.getters['map/getDeviceByCode'](elem.stationControlCode); + // const station = this.$store.getters['map/getDeviceByCode'](control.stationCode); + // const newOperate = { + // type: operate.type, + // name: station.name + // }; + // + // this.doShow(newOperate); + // } + // } } }, mounted() { diff --git a/src/jmapNew/theme/foshan_01/menus/passiveDialog/control.vue b/src/jmapNew/theme/foshan_01/menus/passiveDialog/control.vue index c2d336a61..ccaadd286 100644 --- a/src/jmapNew/theme/foshan_01/menus/passiveDialog/control.vue +++ b/src/jmapNew/theme/foshan_01/menus/passiveDialog/control.vue @@ -2,7 +2,7 @@ - {{ `${requestInfo}请求如下区域的控制模式` }} + {{ `${requestInfo}${$t('menu.passiveDialog.requestAreaControlMode')}` }} - + - + - + - + - 距离对话还有{{ count }}秒,请应答。 + {{ $t('menu.passiveDialog.messageOne') }} {{ count }} {{ $t('menu.passiveDialog.messageTwo') }} - 同意 + {{ $t('menu.passiveDialog.agree') }} - 拒绝 + {{ $t('menu.passiveDialog.refuse') }} @@ -59,8 +59,10 @@