From b3743326bc205f6cc985a0e50c6b07a335f90cd0 Mon Sep 17 00:00:00 2001 From: fan <18706759286@163.com> Date: Thu, 14 May 2020 16:04:23 +0800 Subject: [PATCH 1/7] =?UTF-8?q?=E8=A5=BF=E5=AE=89=E4=BA=8C=E5=8F=B7?= =?UTF-8?q?=E7=BA=BF=E4=BF=A1=E5=8F=B7=E6=9C=BA=E8=B0=83=E6=95=B4=E9=80=BB?= =?UTF-8?q?=E8=BE=91=E7=82=B9=E7=81=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/jmapNew/config/skinCode/xian_02.js | 1 + src/jmapNew/shape/Signal/index.js | 82 +++++++++++++++++--------- 2 files changed, 56 insertions(+), 27 deletions(-) diff --git a/src/jmapNew/config/skinCode/xian_02.js b/src/jmapNew/config/skinCode/xian_02.js index 3b68afa5f..c38ba3c66 100644 --- a/src/jmapNew/config/skinCode/xian_02.js +++ b/src/jmapNew/config/skinCode/xian_02.js @@ -165,6 +165,7 @@ class SkinCode extends defaultStyle { }, lamp: { bgShow: false, // 是否被选中 + logicColor: true, // cbtc通信是否影响灯颜色 guidName: 'singleRY', // 默认引导类型 borderVariable: true, // 信号灯边框可变 stopWidth: 2, // 禁止线宽度 diff --git a/src/jmapNew/shape/Signal/index.js b/src/jmapNew/shape/Signal/index.js index c60395f25..7d5ff5f46 100644 --- a/src/jmapNew/shape/Signal/index.js +++ b/src/jmapNew/shape/Signal/index.js @@ -314,39 +314,67 @@ class Signal extends Group { } // 关闭 - close() { - if (this.count == 2) { // 双灯 - this.lamps[0] && this.lamps[0].setColor(this.style.Signal.lamp.redColor); - this.lamps[1] && this.lamps[1].setColor(this.style.backgroundColor); - } else if (this.count == 1) { // 单灯 - if (this.model.useType == '05' && this.lamps[0]) { // 调车信号机 - this.lamps[0].setColor(this.style.Signal.lamp.blueColor); - } else { - this.lamps[0].setColor(this.style.Signal.lamp.redColor); + close(logicLight) { + if (this.style.Signal.lamp.logicColor && logicLight) { + // 逻辑点灯影响灯颜色仅西安二且暂无双灯 + if (this.count == 1) { + this.lamps[0].setColor(this.style.Signal.lamp.grayColor); + this.insideTriangle.show(); + this.insideTriangle.setStyle({fill: this.style.Signal.lamp.redColor}); + } + } else { + if (this.count == 2) { // 双灯 + this.lamps[0] && this.lamps[0].setColor(this.style.Signal.lamp.redColor); + this.lamps[1] && this.lamps[1].setColor(this.style.backgroundColor); + } else if (this.count == 1) { // 单灯 + if (this.model.useType == '05' && this.lamps[0]) { // 调车信号机 + this.lamps[0].setColor(this.style.Signal.lamp.blueColor); + } else { + this.lamps[0].setColor(this.style.Signal.lamp.redColor); + } } } + } /* 正向开放*/ - openPositive() { - this.lamps[0] && this.lamps[0].setColor(this.style.Signal.lamp.greenColor); - this.lamps[1] && this.lamps[1].setColor(this.style.backgroundColor); // 设置黑色 - this.virtualSignal && this.virtualSignal.setColor(this.style.Signal.lamp.greenColor); - if (this.style.Signal.lamp.guidName === 'doubleAndBase') { // 设置底座颜色 - this.sigPost.setColor('#00FF00'); - if (this.model.logicLight) { - this.lamps[0] && this.lamps[0].setColor(this.style.Signal.lamp.blueColor); + openPositive(logicLight) { + if (this.style.Signal.lamp.logicColor && logicLight) { + // 逻辑点灯影响灯颜色仅西安二且暂无双灯 + if (this.count == 1) { + this.lamps[0].setColor(this.style.Signal.lamp.grayColor); + this.insideTriangle.show(); + this.insideTriangle.setStyle({fill: this.style.Signal.lamp.greenColor}); + } + } else { + this.lamps[0] && this.lamps[0].setColor(this.style.Signal.lamp.greenColor); + this.lamps[1] && this.lamps[1].setColor(this.style.backgroundColor); // 设置黑色 + this.virtualSignal && this.virtualSignal.setColor(this.style.Signal.lamp.greenColor); + if (this.style.Signal.lamp.guidName === 'doubleAndBase') { // 设置底座颜色 + this.sigPost.setColor('#00FF00'); + if (this.model.logicLight) { + this.lamps[0] && this.lamps[0].setColor(this.style.Signal.lamp.blueColor); + } } } + } /* 侧向开放 */ - openLateral() { - this.lamps[0] && this.lamps[0].setColor(this.style.Signal.lamp.yellowColor); - this.lamps[1] && this.lamps[1].setColor(this.style.backgroundColor); - if (this.style.Signal.lamp.guidName === 'doubleAndBase') { // 设置底座颜色 - this.sigPost.setColor('#00FF00'); - if (this.model.logicLight) { // 设置哈尔滨逻辑点灯 颜色 - this.lamps[0] && this.lamps[0].setColor(this.style.Signal.lamp.blueColor); + openLateral(logicLight) { + if (this.style.Signal.lamp.logicColor && logicLight) { + if (this.count == 1) { + this.lamps[0].setColor(this.style.Signal.lamp.grayColor); + this.insideTriangle.show(); + this.insideTriangle.setStyle({fill: this.style.Signal.lamp.yellowColor}); + } + } else { + this.lamps[0] && this.lamps[0].setColor(this.style.Signal.lamp.yellowColor); + this.lamps[1] && this.lamps[1].setColor(this.style.backgroundColor); + if (this.style.Signal.lamp.guidName === 'doubleAndBase') { // 设置底座颜色 + this.sigPost.setColor('#00FF00'); + if (this.model.logicLight) { // 设置哈尔滨逻辑点灯 颜色 + this.lamps[0] && this.lamps[0].setColor(this.style.Signal.lamp.blueColor); + } } } } @@ -529,9 +557,9 @@ class Signal extends Group { model.blockade && this.block(); /** 设置灯的颜色 */ model.redOpen && model.yellowOpen && !model.greenOpen && this.guid(); // 引导信号显示 - model.redOpen && !model.yellowOpen && !model.greenOpen && this.close(); // 信号关闭 - model.greenOpen && !model.redOpen && !model.yellowOpen && this.openPositive(); // 信号正向开放 - model.yellowOpen && !model.redOpen && !model.greenOpen && this.openLateral(); // 信号侧向开放 + model.redOpen && !model.yellowOpen && !model.greenOpen && this.close(model.logicLight); // 信号关闭 + model.greenOpen && !model.redOpen && !model.yellowOpen && this.openPositive(model.logicLight); // 信号正向开放 + model.yellowOpen && !model.redOpen && !model.greenOpen && this.openLateral(model.logicLight); // 信号侧向开放 /** 进路交人工控或自动控 */ !model.atsControl && this.setArtificialRouteClose(); // 联锁自动进路通过 From b735cd5b063b12c5998370a5db4253aa16b3b0e8 Mon Sep 17 00:00:00 2001 From: zyy <1787816799@qq.com> Date: Thu, 14 May 2020 16:43:55 +0800 Subject: [PATCH 2/7] =?UTF-8?q?=E8=B0=83=E6=95=B4=E5=8C=BA=E6=AE=B5?= =?UTF-8?q?=E5=9B=9E=E8=BD=A6=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/jmapNew/config/skinCode/fuzhou_01.js | 1 - src/views/newMap/newMapdraft/mapoperate/ControlDraft.vue | 4 ++-- src/views/newMap/newMapdraft/mapoperate/section/index.vue | 1 + 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/jmapNew/config/skinCode/fuzhou_01.js b/src/jmapNew/config/skinCode/fuzhou_01.js index b0b3def8f..02bc12167 100644 --- a/src/jmapNew/config/skinCode/fuzhou_01.js +++ b/src/jmapNew/config/skinCode/fuzhou_01.js @@ -413,7 +413,6 @@ class SkinCode extends defaultStyle { block: false // 封锁显示 } }; - this[deviceType.Line] = { lineColor: '#FFFFFF' // 线条颜色 }; diff --git a/src/views/newMap/newMapdraft/mapoperate/ControlDraft.vue b/src/views/newMap/newMapdraft/mapoperate/ControlDraft.vue index 061d81f27..1adf5f3be 100644 --- a/src/views/newMap/newMapdraft/mapoperate/ControlDraft.vue +++ b/src/views/newMap/newMapdraft/mapoperate/ControlDraft.vue @@ -220,8 +220,8 @@ export default { } }, typeChange(type) { // 根据类型来选择功能按钮列表 - this.$refs.dataform && this.$refs.dataform.resetFields(); - this.$refs.make && this.$refs.make.resetFields(); + this.$refs.dataform && this.$refs.dataform.resetFields(); + this.$refs.make && this.$refs.make.resetFields(); this.addModel.automaticRouteCode = ''; this.addModel.cycleCode = ''; this.addModel.concentrateStationList = ''; diff --git a/src/views/newMap/newMapdraft/mapoperate/section/index.vue b/src/views/newMap/newMapdraft/mapoperate/section/index.vue index 898ee8e20..1b958e548 100644 --- a/src/views/newMap/newMapdraft/mapoperate/section/index.vue +++ b/src/views/newMap/newMapdraft/mapoperate/section/index.vue @@ -1203,6 +1203,7 @@ export default { ); models = [...models, ...deleteObjAssociatedSection]; _that.$emit('updateMapModel', models); + this.clear(); _that.deviceSelect(); }) .catch(error => { From abec4b2b4cfa54311b53cd4f38211c1956fa2e65 Mon Sep 17 00:00:00 2001 From: fan <18706759286@163.com> Date: Thu, 14 May 2020 16:45:48 +0800 Subject: [PATCH 3/7] =?UTF-8?q?=E8=A5=BF=E5=AE=89=E4=BA=8C=E5=8F=B7?= =?UTF-8?q?=E7=BA=BF=E6=B7=BB=E5=8A=A0=E6=98=AF=E5=90=A6=E7=81=AD=E7=81=AF?= =?UTF-8?q?=E6=98=BE=E7=A4=BA(CTC=E7=BA=A7)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/utils/baseUrl.js | 4 +-- src/utils/stomp.js | 2 +- .../newMapdraft/mapoperate/signal/create.vue | 3 +- .../newMapdraft/mapoperate/signal/index.vue | 34 ++++++++++++++++--- 4 files changed, 35 insertions(+), 8 deletions(-) diff --git a/src/utils/baseUrl.js b/src/utils/baseUrl.js index e9046878d..7cedc6817 100644 --- a/src/utils/baseUrl.js +++ b/src/utils/baseUrl.js @@ -2,9 +2,9 @@ export function getBaseUrl() { let BASE_API; if (process.env.NODE_ENV === 'development') { // BASE_API = 'https://joylink.club/jlcloud'; - BASE_API = 'https://test.joylink.club/jlcloud'; + // BASE_API = 'https://test.joylink.club/jlcloud'; // BASE_API = 'http://192.168.3.5:9000'; // 袁琪 - // BASE_API = 'http://192.168.3.6:9000'; // 旭强 + BASE_API = 'http://192.168.3.6:9000'; // 旭强 // BASE_API = 'http://192.168.3.41:9000'; // 张赛 // BASE_API = 'http://192.168.3.82:9000'; // 杜康 // BASE_API = 'http://192.168.3.41:9000'; // 张赛 diff --git a/src/utils/stomp.js b/src/utils/stomp.js index 2febbf668..b6a9b8fd9 100644 --- a/src/utils/stomp.js +++ b/src/utils/stomp.js @@ -22,7 +22,7 @@ export function creatSubscribe(topic, header) { function callback(Response) { if (store) { var data = JSON.parse(Response.body); - // console.log(Response.body); + console.log(Response.body); store.dispatch('socket/setStomp', data); } else { callback(Response); diff --git a/src/views/newMap/newMapdraft/mapoperate/signal/create.vue b/src/views/newMap/newMapdraft/mapoperate/signal/create.vue index 3585a6118..d218ca050 100644 --- a/src/views/newMap/newMapdraft/mapoperate/signal/create.vue +++ b/src/views/newMap/newMapdraft/mapoperate/signal/create.vue @@ -201,7 +201,8 @@ export default { guideShow: false, stationCode: this.addModel.stationCode, callOn: true, - turnBack: false + turnBack: false, + ctc: true }; this.sectionList.forEach(elem => { diff --git a/src/views/newMap/newMapdraft/mapoperate/signal/index.vue b/src/views/newMap/newMapdraft/mapoperate/signal/index.vue index 8b59dcb0c..580f45386 100644 --- a/src/views/newMap/newMapdraft/mapoperate/signal/index.vue +++ b/src/views/newMap/newMapdraft/mapoperate/signal/index.vue @@ -17,6 +17,9 @@ + + + @@ -72,6 +75,15 @@
批量设置引导信号
+
+ + + + + +
+ 设置灭灯显示 +
@@ -106,6 +118,7 @@ export default { data() { return { activeName: 'first', + collapseActive: '', lazy: true, SignalDirectionList: [ { code: false, name: '向左' }, @@ -153,7 +166,8 @@ export default { guidePosition: { x: 0, y: 0 }, interlockStationCode: '', callOn: true, - turnBack: false + turnBack: false, + ctc: true // 是否灭灯显示 }, addModel: { number: 2 @@ -164,6 +178,9 @@ export default { ciModel: { stationList: [], ciStation: [] + }, + ctcModel: { + ctc: true } }; }, @@ -245,7 +262,8 @@ export default { { prop: 'guidePosition.y', firstLevel: 'guidePosition', secondLevel: 'y', label: 'y:', type: 'number', labelWidth: '25px' } ] }, { prop: 'callOn', label: '是否引导信号:', type: 'checkbox'}, - { prop: 'turnBack', label: '是否折返进路始端:', type: 'checkbox', isHidden: this.editModel.virtual} + { prop: 'turnBack', label: '是否折返进路始端:', type: 'checkbox', isHidden: this.editModel.virtual}, + { prop: 'ctc', label: '是否灭灯显示(CTC级)', type: 'checkbox'} ] }, map: { @@ -421,10 +439,8 @@ export default { }, virtualChange(val) { if (val) { - this.editModel.callOn = false; this.editModel.turnBack = false; } else { - this.editModel.callOn = true; this.editModel.turnBack = false; } }, @@ -462,6 +478,16 @@ export default { this.$emit('updateMapModel', models); this.$message.success('数据构建成功!'); }, + setCtcShow() { + const models = []; + this.signalList.forEach(item => { + const signalModel = deepAssign({}, item); // 深拷贝 + signalModel.ctc = this.ctcModel.ctc; + models.push(signalModel); + }); + this.$emit('updateMapModel', models); + this.$message.success('数据构建成功!'); + }, // 寻找信号机关联区段 findSection(signal) { // 01 向左 02 向右 From 126278ee01d2669a00a2054b6b40874ac1c60b7f Mon Sep 17 00:00:00 2001 From: fan <18706759286@163.com> Date: Thu, 14 May 2020 16:53:58 +0800 Subject: [PATCH 4/7] =?UTF-8?q?=E7=8A=B6=E6=80=81=E8=A1=A8=E7=A4=BA?= =?UTF-8?q?=E9=81=93=E5=B2=94=E6=95=85=E9=9A=9C=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/utils/baseUrl.js | 4 ++-- .../newMap/newMapdraft/mapoperate/controlLamp.vue | 15 +++++++++++---- 2 files changed, 13 insertions(+), 6 deletions(-) diff --git a/src/utils/baseUrl.js b/src/utils/baseUrl.js index 7cedc6817..e9046878d 100644 --- a/src/utils/baseUrl.js +++ b/src/utils/baseUrl.js @@ -2,9 +2,9 @@ export function getBaseUrl() { let BASE_API; if (process.env.NODE_ENV === 'development') { // BASE_API = 'https://joylink.club/jlcloud'; - // BASE_API = 'https://test.joylink.club/jlcloud'; + BASE_API = 'https://test.joylink.club/jlcloud'; // BASE_API = 'http://192.168.3.5:9000'; // 袁琪 - BASE_API = 'http://192.168.3.6:9000'; // 旭强 + // BASE_API = 'http://192.168.3.6:9000'; // 旭强 // BASE_API = 'http://192.168.3.41:9000'; // 张赛 // BASE_API = 'http://192.168.3.82:9000'; // 杜康 // BASE_API = 'http://192.168.3.41:9000'; // 张赛 diff --git a/src/views/newMap/newMapdraft/mapoperate/controlLamp.vue b/src/views/newMap/newMapdraft/mapoperate/controlLamp.vue index 7ea7e21ad..b02f3c47f 100644 --- a/src/views/newMap/newMapdraft/mapoperate/controlLamp.vue +++ b/src/views/newMap/newMapdraft/mapoperate/controlLamp.vue @@ -263,8 +263,8 @@ export default { }, methods: { typeChange(type) { - this.$refs.dataform && this.$refs.dataform.resetFields(); - this.$refs.make && this.$refs.make.resetFields(); + this.$refs.dataform && this.$refs.dataform.resetFields(); + this.$refs.make && this.$refs.make.resetFields(); this.addModel.type = type; this.editModel.type = type; }, @@ -288,6 +288,7 @@ export default { this.returnModeGroupList = []; this.controlSwitchList = []; this.AxleList = []; + this.SwitchFaultList = []; indicatorLightList.forEach(item => { switch (item._type) { case 'AtsControl': @@ -341,6 +342,9 @@ export default { case 'Axle': this.AxleList.push(item); break; + case 'SwitchFault': + this.SwitchFaultList.push(item); + break; } }); }, @@ -397,6 +401,9 @@ export default { case 'Axle': this.selectLists = this.AxleList; break; + case 'SwitchFault': + this.selectLists = this.SwitchFaultList; + break; default : this.selectLists = this.intersiteControlList; break; @@ -414,8 +421,8 @@ export default { this.addModel.switchCode = selected.code; } } else if (selected && this.controlLampTypeList.includes(selected._type)) { - this.$refs.dataform && this.$refs.dataform.resetFields(); - this.$refs.make && this.$refs.make.resetFields(); + this.$refs.dataform && this.$refs.dataform.resetFields(); + this.$refs.make && this.$refs.make.resetFields(); this.activeName = 'first'; this.editModel = deepAssign(this.editModel, selected); this.editModel.type = selected._type; From ccf186e98e4b3e9810986577d6b66326f7a0bb4d Mon Sep 17 00:00:00 2001 From: zyy <1787816799@qq.com> Date: Thu, 14 May 2020 16:54:31 +0800 Subject: [PATCH 5/7] =?UTF-8?q?=E8=B0=83=E6=95=B4=E5=8C=BA=E6=AE=B5?= =?UTF-8?q?=E5=81=9C=E8=BD=A6=E7=82=B9=E5=81=8F=E7=A7=BB=E9=87=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/utils/baseUrl.js | 4 +-- .../newMapdraft/mapoperate/section/index.vue | 26 +++++-------------- 2 files changed, 9 insertions(+), 21 deletions(-) diff --git a/src/utils/baseUrl.js b/src/utils/baseUrl.js index 7cedc6817..e9046878d 100644 --- a/src/utils/baseUrl.js +++ b/src/utils/baseUrl.js @@ -2,9 +2,9 @@ export function getBaseUrl() { let BASE_API; if (process.env.NODE_ENV === 'development') { // BASE_API = 'https://joylink.club/jlcloud'; - // BASE_API = 'https://test.joylink.club/jlcloud'; + BASE_API = 'https://test.joylink.club/jlcloud'; // BASE_API = 'http://192.168.3.5:9000'; // 袁琪 - BASE_API = 'http://192.168.3.6:9000'; // 旭强 + // BASE_API = 'http://192.168.3.6:9000'; // 旭强 // BASE_API = 'http://192.168.3.41:9000'; // 张赛 // BASE_API = 'http://192.168.3.82:9000'; // 杜康 // BASE_API = 'http://192.168.3.41:9000'; // 张赛 diff --git a/src/views/newMap/newMapdraft/mapoperate/section/index.vue b/src/views/newMap/newMapdraft/mapoperate/section/index.vue index 1b958e548..26866d41b 100644 --- a/src/views/newMap/newMapdraft/mapoperate/section/index.vue +++ b/src/views/newMap/newMapdraft/mapoperate/section/index.vue @@ -1005,26 +1005,15 @@ export default { edit() { this.$refs['dataform'].validate(valid => { if (valid) { - if ( - this.editModel.type === '03' && - this.editModel.leftSectionCode && - this.editModel.rightSectionCode - ) { + if (this.editModel.type === '03' && this.editModel.leftSectionCode && this.editModel.rightSectionCode) { this.$messageBox('道岔区段应仅有一侧关联区段!'); return; } let models = []; - const model = deepAssign(this.editModel, { - _type: 'Section' - }); // 修改元素model - if ( - model.lengthFact > 5 && - (model.transferTrack || - model.reentryTrack || - model.standTrack) - ) { - model.leftStopPointOffset = 5; - model.rightStopPointOffset = model.lengthFact - 5; + const model = deepAssign(this.editModel, { _type: 'Section' }); // 修改元素model + if (model.lengthFact > 5 && (model.transferTrack || model.reentryTrack || model.standTrack)) { + model.leftStopPointOffset = model.leftStopPointOffset || 5; + model.rightStopPointOffset = model.rightStopPointOffset || model.lengthFact - 5; } const changeSectionList = this.handleOtherSectionChange(model); models = [model, ...changeSectionList]; @@ -1091,9 +1080,8 @@ export default { lengthFact += model.lengthFact; copySection.lengthFact = lengthFact.toFixed(3); // 自动获取 物理区段的 实际长度 是由逻辑区段相加 if (copySection.lengthFact > 5) { - copySection.leftStopPointOffset = 5; - copySection.rightStopPointOffset = - copySection.lengthFact - 5; + copySection.leftStopPointOffset = copySection.leftStopPointOffset || 5; + copySection.rightStopPointOffset = copySection.rightStopPointOffset || copySection.lengthFact - 5; } updataFlag = true; } From 4f8de9cc6ab283a4cb8b3f5d8d008391ea2a4bf8 Mon Sep 17 00:00:00 2001 From: fan <18706759286@163.com> Date: Thu, 14 May 2020 17:03:30 +0800 Subject: [PATCH 6/7] =?UTF-8?q?=E4=BF=A1=E5=8F=B7=E6=9C=BA=E6=89=B9?= =?UTF-8?q?=E9=87=8F=E6=93=8D=E4=BD=9C=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../newMapdraft/mapoperate/signal/index.vue | 139 +++++++++--------- 1 file changed, 72 insertions(+), 67 deletions(-) diff --git a/src/views/newMap/newMapdraft/mapoperate/signal/index.vue b/src/views/newMap/newMapdraft/mapoperate/signal/index.vue index 580f45386..abc855339 100644 --- a/src/views/newMap/newMapdraft/mapoperate/signal/index.vue +++ b/src/views/newMap/newMapdraft/mapoperate/signal/index.vue @@ -17,73 +17,78 @@ - - - - - - - - -
- 构建信号机偏移量 - {{ $t('map.clearHint') }} -
-
- - - - - - - -
- 设置全部信号机类型 -
-
- - - - - - - - - - - - -
- 设置归属联锁站 -
-
-
- 批量设置引导信号 -
-
- - - - - -
- 设置灭灯显示 -
+ + + + + + + +
+ 设置 + {{ $t('map.clearHint') }} +
+
+ + + + + + + + +
+ 设置 +
+
+ + + + + + + + + + + + + +
+ 设置 +
+
+ +
+ 设置 +
+
+ + + + + + +
+ 设置 +
+
+
From 027fe4346785ac4230ce5a41f26fd54b0e02de39 Mon Sep 17 00:00:00 2001 From: fan <18706759286@163.com> Date: Thu, 14 May 2020 17:24:35 +0800 Subject: [PATCH 7/7] =?UTF-8?q?=E5=88=A0=E9=99=A4=E6=97=A5=E5=BF=97?= =?UTF-8?q?=EF=BC=8C=E4=BF=A1=E5=8F=B7=E6=9C=BA=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/jmapNew/shape/Signal/index.js | 18 ++++++++++++++++++ src/utils/stomp.js | 2 +- src/views/publish/publishLesson/index.vue | 4 ++-- 3 files changed, 21 insertions(+), 3 deletions(-) diff --git a/src/jmapNew/shape/Signal/index.js b/src/jmapNew/shape/Signal/index.js index 7d5ff5f46..6e9fc6fb6 100644 --- a/src/jmapNew/shape/Signal/index.js +++ b/src/jmapNew/shape/Signal/index.js @@ -321,6 +321,12 @@ class Signal extends Group { this.lamps[0].setColor(this.style.Signal.lamp.grayColor); this.insideTriangle.show(); this.insideTriangle.setStyle({fill: this.style.Signal.lamp.redColor}); + setTimeout(()=> { + this.insideTriangle.setStyle({fill: '#000'}); + }, 500); + setTimeout(()=> { + this.insideTriangle.setStyle({fill: this.style.Signal.lamp.redColor}); + }, 1000); } } else { if (this.count == 2) { // 双灯 @@ -345,6 +351,12 @@ class Signal extends Group { this.lamps[0].setColor(this.style.Signal.lamp.grayColor); this.insideTriangle.show(); this.insideTriangle.setStyle({fill: this.style.Signal.lamp.greenColor}); + setTimeout(()=> { + this.insideTriangle.setStyle({fill: '#000'}); + }, 500); + setTimeout(()=> { + this.insideTriangle.setStyle({fill: this.style.Signal.lamp.greenColor}); + }, 1000); } } else { this.lamps[0] && this.lamps[0].setColor(this.style.Signal.lamp.greenColor); @@ -366,6 +378,12 @@ class Signal extends Group { this.lamps[0].setColor(this.style.Signal.lamp.grayColor); this.insideTriangle.show(); this.insideTriangle.setStyle({fill: this.style.Signal.lamp.yellowColor}); + setTimeout(()=> { + this.insideTriangle.setStyle({fill: '#000'}); + }, 1000); + setTimeout(()=> { + this.insideTriangle.setStyle({fill: this.style.Signal.lamp.yellowColor}); + }, 2000); } } else { this.lamps[0] && this.lamps[0].setColor(this.style.Signal.lamp.yellowColor); diff --git a/src/utils/stomp.js b/src/utils/stomp.js index b6a9b8fd9..2febbf668 100644 --- a/src/utils/stomp.js +++ b/src/utils/stomp.js @@ -22,7 +22,7 @@ export function creatSubscribe(topic, header) { function callback(Response) { if (store) { var data = JSON.parse(Response.body); - console.log(Response.body); + // console.log(Response.body); store.dispatch('socket/setStomp', data); } else { callback(Response); diff --git a/src/views/publish/publishLesson/index.vue b/src/views/publish/publishLesson/index.vue index 2fe2f9b43..c64889c4e 100644 --- a/src/views/publish/publishLesson/index.vue +++ b/src/views/publish/publishLesson/index.vue @@ -139,9 +139,9 @@ export default { this.$message.success(this.$t('publish.deleteSuccess')); this.reloadTable(); localStore.remove('mapId'); - }).catch(() => { + }).catch((error) => { this.reloadTable(); - this.$messageBox(this.$t('error.deleteFailed')); + this.$messageBox(this.$t('error.deleteFailed') + ':' + error.message); }); }).catch(() => { }); },