From 9b68feaba53adb8da5b881498a4334d7565147d9 Mon Sep 17 00:00:00 2001 From: zyy <1787816799@qq.com> Date: Thu, 9 Apr 2020 18:39:27 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E8=B0=83=E6=95=B4=E5=8C=BA=E6=AE=B5?= =?UTF-8?q?=E5=AD=97=E6=AE=B5=E6=98=BE=E9=9A=90=E5=88=A4=E6=96=AD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../newMapdraft/mapoperate/section/index.vue | 85 ++++++++----------- 1 file changed, 35 insertions(+), 50 deletions(-) diff --git a/src/views/newMap/newMapdraft/mapoperate/section/index.vue b/src/views/newMap/newMapdraft/mapoperate/section/index.vue index 76c89cfc1..bc61699a7 100644 --- a/src/views/newMap/newMapdraft/mapoperate/section/index.vue +++ b/src/views/newMap/newMapdraft/mapoperate/section/index.vue @@ -143,23 +143,23 @@ export default { { prop: 'namePosition.x', firstLevel: 'namePosition', secondLevel: 'x', label: 'x:', type: 'number', labelWidth: '25px' }, { prop: 'namePosition.y', firstLevel: 'namePosition', secondLevel: 'y', label: 'y:', type: 'number', labelWidth: '25px' } ] }, - { prop: 'type', label: this.$t('map.sectionType'), type: 'select', optionLabel: 'name', optionValue: 'code', options: this.SectionTypeList}, - { prop: 'leftSectionCode', label: this.$t('map.leftAssociatedSection'), type: 'selectHover', optionLabel: 'name&&code', optionValue: 'code', clearable: true, options: this.switchAndPhySicalSectionList, hover: this.hover, buttonType: 'leftSection', buttonShowType: this.isLeftSectionButtonShow, isHidden: !this.hasAssociatedSection}, - { prop: 'rightSectionCode', label: this.$t('map.rightAssociatedSection'), type: 'selectHover', optionLabel: 'name&&code', optionValue: 'code', clearable: true, options: this.switchAndPhySicalSectionList, hover: this.hover, buttonType: 'rightSection', buttonShowType: this.isRightSectionButtonShow, isHidden: !this.hasAssociatedSection}, - { prop: 'parentCode', label: this.$t('map.associatedSection'), type: 'select', mode: true, optionLabel: 'name&&code', optionValue: 'code', disabled: true, options: this.sectionList, isHidden: !this.isParentCode }, + { prop: 'type', label: this.$t('map.sectionType'), type: 'select', optionLabel: 'name', optionValue: 'code', options: this.SectionTypeList }, // 区段类型 + { prop: 'leftSectionCode', label: this.$t('map.leftAssociatedSection'), type: 'selectHover', optionLabel: 'name&&code', optionValue: 'code', clearable: true, options: this.switchAndPhySicalSectionList, hover: this.hover, buttonType: 'leftSection', buttonShowType: this.isLeftSectionButtonShow, isHidden: !this.hasAssociatedSection}, // 左关联区段 + { prop: 'rightSectionCode', label: this.$t('map.rightAssociatedSection'), type: 'selectHover', optionLabel: 'name&&code', optionValue: 'code', clearable: true, options: this.switchAndPhySicalSectionList, hover: this.hover, buttonType: 'rightSection', buttonShowType: this.isRightSectionButtonShow, isHidden: !this.hasAssociatedSection}, // 右关联区段 + { prop: 'parentCode', label: this.$t('map.associatedSection'), type: 'select', mode: true, optionLabel: 'name&&code', optionValue: 'code', disabled: true, options: this.sectionList, isHidden: !this.isParentCode }, // 所属物理/道岔区段code { prop: 'sepTypeLeft', label: this.$t('map.sepTypeLeft'), type: 'select', optionLabel: 'name', optionValue: 'code', options: this.SectionSepTypeList, isHidden: !this.isSwitchSectionType }, { prop: 'sepTypeRight', label: this.$t('map.sepTypeRight'), type: 'select', optionLabel: 'name', optionValue: 'code', options: this.SectionSepTypeList, isHidden: !this.isSwitchSectionType }, { prop: 'points', label: this.$t('map.segmentCoordinates'), type: 'points', width: '100px', isHidden: !this.isPointsShow, pointDisabled: this.isStationCodeDisabled, addPoint: this.addPoint, delPoint: this.delPoint, lastDisabled: true }, - { prop: 'logicSectionStartOffset', label: this.$t('map.logicalSectionStartOffset'), type: 'number', min: 0, width: '150px', isHidden: !this.isLSectionOffsetShow, disabled: true}, - { prop: 'logicSectionEndOffset', label: this.$t('map.logicalSectionEndOffset'), type: 'number', min: 0, width: '150px', isHidden: !this.isLSectionOffsetShow, disabled: true}, - { prop: 'standTrack', label: this.$t('map.isStandTrack'), type: 'checkbox', isHidden: !this.isStandTrackShow }, // 1 + { prop: 'logicSectionStartOffset', label: this.$t('map.logicalSectionStartOffset'), type: 'number', min: 0, width: '150px', isHidden: !this.isStationCodeDisabled, disabled: true}, + { prop: 'logicSectionEndOffset', label: this.$t('map.logicalSectionEndOffset'), type: 'number', min: 0, width: '150px', isHidden: !this.isStationCodeDisabled, disabled: true}, + { prop: 'standTrack', label: this.$t('map.isStandTrack'), type: 'checkbox', isHidden: !this.isStandTrackShow }, // 是否站台轨 { prop: 'standTrackName', label: this.$t('map.standTrackName'), type: 'input', isHidden: !this.isstandTrackNameShow }, { prop: 'standTrackNamePosition', label: this.$t('map.standTrackNamePosition'), type: 'coordinate', width: '150px', isHidden: !this.isstandTrackNameShow, children: [ { prop: 'standTrackNamePosition.x', firstLevel: 'standTrackNamePosition', secondLevel: 'x', label: 'x:', type: 'number', labelWidth: '20px'}, { prop: 'standTrackNamePosition.y', firstLevel: 'standTrackNamePosition', secondLevel: 'y', label: 'y:', type: 'number', labelWidth: '20px'} ] }, - { prop: 'reentryTrack', label: this.$t('map.isReentryTrack'), type: 'checkbox', isHidden: !this.isStandTrackShow }, // 1 + { prop: 'reentryTrack', label: this.$t('map.isReentryTrack'), type: 'checkbox', isHidden: !this.isStandTrackShow }, // 是否折返轨 { prop: 'reentryTrackName', label: this.$t('map.reentryTrackName'), type: 'input', isHidden: !this.isreentryTrackName }, { prop: 'reentryTrackNamePosition', label: this.$t('map.reentryTrackNamePosition'), type: 'coordinate', width: '150px', isHidden: !this.isreentryTrackName, children: [ @@ -167,7 +167,7 @@ export default { { prop: 'reentryTrackNamePosition.y', firstLevel: 'reentryTrackNamePosition', secondLevel: 'y', label: 'y:', type: 'number', labelWidth: '20px'} ] }, - { prop: 'transferTrack', label: this.$t('map.isTransferTrack'), type: 'checkbox', isHidden: !this.isStandTrackShow }, // 1 + { prop: 'transferTrack', label: this.$t('map.isTransferTrack'), type: 'checkbox', isHidden: !this.isStandTrackShow }, // 是否转换轨 { prop: 'transferTrackName', label: this.$t('map.transferTrackName'), type: 'input', isHidden: !this.istransferTrackName }, { prop: 'transferTrackNamePosition', label: this.$t('map.transferTrackNamePosition'), type: 'coordinate', width: '150px', isHidden: !this.istransferTrackName, children: [ @@ -180,10 +180,10 @@ export default { { prop: 'destinationCodePoint.y', firstLevel: 'destinationCodePoint', secondLevel: 'y', label: 'y:', type: 'number', labelWidth: '20px'} ] }, - { prop: 'switchSection', label: this.$t('map.isSwitchSection'), type: 'checkbox', isHidden: !this.isAssociatedSwitchSectionshow, disabled: true }, - { prop: 'relSwitchCode', label: this.$t('map.relSwitchCode'), type: 'select', optionLabel: 'code&&name', optionValue: 'code', options: this.switchList, change: true, deviceChange: this.deviceChange, isHidden: !this.isRelSwitchCode, disabled: true }, + { prop: 'switchSection', label: this.$t('map.isSwitchSection'), type: 'checkbox', disabled: true }, // 是否关联道岔 + { prop: 'relSwitchCode', label: this.$t('map.relSwitchCode'), type: 'select', optionLabel: 'name&&code', optionValue: 'code', options: this.switchList, isHidden: this.isStandTrackShow, disabled: true }, // 关联道岔 - { prop: 'logicSectionShow', label: this.$t('map.displayLogicalExtents'), type: 'checkbox', isHidden: !this.isSwitchSectionShow }, // 1 + { prop: 'logicSectionShow', label: this.$t('map.displayLogicalExtents'), type: 'checkbox', isHidden: !this.isSwitchSectionType }, // 1 { prop: 'logicSectionNameSort', label: this.$t('map.logicSectionNameSort'), type: 'radio', optionLabel: 'label', optionValue: 'value', isHidden: !this.isLogicSectionNameSort, radioList: [ {value: true, label: this.$t('map.fromSmallToLarge')}, {value: false, label: this.$t('map.fromLargeToSmall')} @@ -195,8 +195,8 @@ export default { map: { name: this.$t('map.mapData'), item: [ - { prop: 'stationCode', label: this.$t('map.equipmentStation') + ':', type: 'select', mode: true, optionLabel: 'name&&code', optionValue: 'code', disabled: this.isStationCodeDisabled, options: this.centralizedStationList, isHidden: this.isLSectionOffsetShow}, - { prop: 'lengthFact', label: this.$t('map.actualLength') + ':', type: 'number', min: 0, placeholder: this.$t('map.meter'), isHidden: this.isLengthFactShow }, + { prop: 'stationCode', label: this.$t('map.equipmentStation') + ':', type: 'select', mode: true, optionLabel: 'name&&code', optionValue: 'code', disabled: this.isStationCodeDisabled, options: this.centralizedStationList, isHidden: this.isStationCodeDisabled}, + { prop: 'lengthFact', label: this.$t('map.actualLength') + ':', type: 'number', min: 0, placeholder: this.$t('map.meter'), isHidden: !this.hasAssociatedSection }, { prop: 'leftStopPointOffset', label: this.$t('map.leftStopPointOffset'), type: 'number', min: 0, disabled: true, isHidden: !this.isStopPointOffset }, { prop: 'rightStopPointOffset', label: this.$t('map.rightStopPointOffset'), type: 'number', min: 0, disabled: true, isHidden: !this.isStopPointOffset }, { prop: 'region', label: this.$t('map.sectionColon'), type: 'select', optionLabel: 'label', optionValue: 'value', options: this.regionList, isHidden: !this.sectionColonShow }, @@ -302,15 +302,27 @@ export default { }, // 判断显隐 true 显示 false 隐藏 - isParentCode() { - return this.editModel.type == '02' || this.editModel.relSwitchCode; - }, isStationCodeDisabled() { return this.editModel.type == '02'; }, isSwitchSectionType() { return this.editModel.type !== '04'; }, + isLogicSectionNameSort() { // 逻辑区段排序 判断 + return this.editModel.type == '01'; + }, + isPointsShow() { + return this.editModel.type !== '04' && this.editModel.points.length > 0; + }, + isStandTrackShow() { + return this.editModel.type != '04' && this.editModel.type != '03'; + }, + hasAssociatedSection() { + return this.editModel.type == '01' || this.editModel.type == '03'; + }, + isParentCode() { + return this.editModel.type == '02' || this.editModel.type == '03'; + }, isstandTrackNameShow() { return this.editModel.type !== '04' && this.editModel.standTrack; }, @@ -326,44 +338,18 @@ export default { isStopPointOffset() { return this.editModel.type !== '04' && (this.editModel.reentryTrack || this.editModel.standTrack || this.editModel.transferTrack); }, - isRelSwitchCode() { - return this.editModel.type !== '04' && this.editModel.switchSection; - }, - isLogicSectionNameSort() { // 逻辑区段排序 判断 - return this.editModel.type === '01' && !this.editModel.switchSection; - }, - isPointsShow() { - return this.editModel.type !== '04' && this.editModel.points.length > 0; - }, - sectionColonShow() { - if (this.$store.state.map.map) { - return this.$store.state.map.map.skinVO.code === '03'; - } - return false; - }, - isSwitchSectionShow() { // 判断道岔区段不显示 - return this.editModel.type !== '04' && !this.editModel.switchSection; - }, - isAssociatedSwitchSectionshow() { - return this.editModel.type !== '04' || this.editModel.type !== '03'; - }, - isStandTrackShow() { - return this.editModel.type !== '04' && this.editModel.type !== '03' && !this.editModel.switchSection; - }, + isLeftSectionButtonShow() { return this.field === 'leftSection'; }, isRightSectionButtonShow() { return this.field === 'rightSection'; }, - hasAssociatedSection() { - return this.editModel.type === '01' || this.editModel.type === '03'; - }, - isLSectionOffsetShow() { - return this.editModel.type === '02'; - }, - isLengthFactShow() { - return this.editModel.type === '02' || this.editModel.type === '04'; + sectionColonShow() { + if (this.$store.state.map.map) { + return this.$store.state.map.map.skinVO.code === '03'; + } + return false; }, centralizedStationList() { let list = []; @@ -417,7 +403,6 @@ export default { this.editModel = deepAssign(this.editModel, selected); this.editModel.logicSectionNum = selected.type === '01' ? selected.logicSectionNum : [0]; this.editModel.points = JSON.parse(JSON.stringify(selected.points)); - console.log(selected, selected.lengthFact, '实际长度'); this.editModel.lengthFact = selected.lengthFact || 0; this.oldPoint = JSON.parse(JSON.stringify(selected.points)); this.oldLeftSectionCode = selected.leftSectionCode; From 4e9ccad9e58e2d6e4044df8656a6e47cb558ce6f Mon Sep 17 00:00:00 2001 From: joylink_cuiweidong <364937672@qq.com> Date: Thu, 9 Apr 2020 18:51:51 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E4=BB=A3=E7=A0=81=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../ningbo_01/menus/dialog/sectionUnLock.vue | 2 +- .../menus/dialog/turnBackControl.vue | 12 +++++++- .../theme/ningbo_01/operationConfig.js | 28 +++++++++++++++++++ 3 files changed, 40 insertions(+), 2 deletions(-) diff --git a/src/jmapNew/theme/ningbo_01/menus/dialog/sectionUnLock.vue b/src/jmapNew/theme/ningbo_01/menus/dialog/sectionUnLock.vue index fc8144152..214c3a945 100644 --- a/src/jmapNew/theme/ningbo_01/menus/dialog/sectionUnLock.vue +++ b/src/jmapNew/theme/ningbo_01/menus/dialog/sectionUnLock.vue @@ -138,7 +138,7 @@ export default { let name = section.name; if (section.type == '02') { const sectionParent = this.$store.getters['map/getDeviceByCode'](section.parentCode); - name = `${sectionParent.name}-${section.name}`; + name = `${sectionParent.name}${section.name}`; } list.push({ name: name, code: section.code }); }); diff --git a/src/jmapNew/theme/ningbo_01/menus/dialog/turnBackControl.vue b/src/jmapNew/theme/ningbo_01/menus/dialog/turnBackControl.vue index 5f45fa8bf..30672b938 100644 --- a/src/jmapNew/theme/ningbo_01/menus/dialog/turnBackControl.vue +++ b/src/jmapNew/theme/ningbo_01/menus/dialog/turnBackControl.vue @@ -75,7 +75,17 @@ export default { return this.dialogShow ? OperationEvent.Command.close.menu.domId : ''; }, domIdConfirm() { - return this.dialogShow ? OperationHandler.getDomIdByOperation(this.operation) : ''; + if (this.dialogShow) { + if (this.operation == OperationEvent.AutoTurnBack.SetAutoTurnBackButton.menu.operation) { + return OperationEvent.AutoTurnBack.SetAutoTurnBackButton.confirm.operation; + } else if (this.operation == OperationEvent.AutoTurnBack.CancelAutoTurnBackButton.menu.operation) { + return OperationEvent.AutoTurnBack.CancelAutoTurnBackButton.confirm.operation; + } else { + return ''; + } + } else { + return ''; + } }, title() { return '自动折返'; diff --git a/src/jmapNew/theme/ningbo_01/operationConfig.js b/src/jmapNew/theme/ningbo_01/operationConfig.js index a94a13ad8..886e3bd11 100644 --- a/src/jmapNew/theme/ningbo_01/operationConfig.js +++ b/src/jmapNew/theme/ningbo_01/operationConfig.js @@ -760,6 +760,34 @@ export default { { deviceType: 'button', orderNum: 1, operateCode: '202', tip: '鼠标右键菜单选择【请求站控】'}, { deviceType: '05', orderNum: 2, operateCode: '2023', tip: '鼠标左键点击【应用】' } ] + }, + { + maxDuration: 15, + minDuration: 8, + operateType: 'Signal_Set_Auto_Turn_Back', + skinCode: '06', + trainingName: '设置自动折返进路({3})', + trainingRemark: '设置自动折返进路', + trainingType: 'Signal', + productTypes: ['02'], + stepVOList: [ + { deviceType: '05', orderNum: 1, operateCode: '900', tip: '鼠标右键菜单选择【设置自动折返】'}, + { deviceType: '05', orderNum: 2, operateCode: '9001', tip: '鼠标左键点击【应用】' } + ] + }, + { + maxDuration: 15, + minDuration: 8, + operateType: 'Signal_Cancel_Auto_Turn_Back', + skinCode: '06', + trainingName: ' 取消自动折返进路({3})', + trainingRemark: ' 取消自动折返进路', + trainingType: 'Signal', + productTypes: ['02'], + stepVOList: [ + { deviceType: '05', orderNum: 1, operateCode: '901', tip: '鼠标右键菜单选择【取消自动折返】'}, + { deviceType: '05', orderNum: 2, operateCode: '9011', tip: '鼠标左键点击【应用】' } + ] } ] };