From ddfddfa292713428e6e1e89be6db95917eeb9085 Mon Sep 17 00:00:00 2001 From: fan <18706759286@163.com> Date: Fri, 14 May 2021 15:05:57 +0800 Subject: [PATCH 1/5] =?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 --- src/jmapNew/map.js | 1 - src/jmapNew/painter.js | 5 +- src/jmapNew/shape/Train/index.js | 1 - .../theme/haerbin_01/menus/menuButton.vue | 108 ++++---- .../nanjing_02/menus/dialog/mapVisual.vue | 255 ++++++++++++++++++ .../theme/nanjing_02/menus/dialog/rps.vue | 95 +++++++ .../theme/nanjing_02/menus/menuBar.vue | 125 ++++++--- .../theme/nanjing_02/menus/menuButton.vue | 160 +++++++---- src/scripts/cmdPlugin/CommandEnum.js | 8 +- src/scripts/cmdPlugin/OperationHandler.js | 12 + src/store/modules/map.js | 3 + src/utils/baseUrl.js | 4 +- .../newMap/mapsystemNew/common/index.vue | 16 +- 13 files changed, 637 insertions(+), 156 deletions(-) create mode 100644 src/jmapNew/theme/nanjing_02/menus/dialog/mapVisual.vue create mode 100644 src/jmapNew/theme/nanjing_02/menus/dialog/rps.vue diff --git a/src/jmapNew/map.js b/src/jmapNew/map.js index 6a24d028d..8bd2b7f69 100644 --- a/src/jmapNew/map.js +++ b/src/jmapNew/map.js @@ -500,7 +500,6 @@ class Jlmap { oDevice['cutOff'] = sectionA.cutOff; } } - this.$painter.update(oDevice); } else if (elem.deviceType == 'SECTION') { const oDevice = this.mapDevice[code]; diff --git a/src/jmapNew/painter.js b/src/jmapNew/painter.js index 5f0c5edd2..5f8c3c671 100644 --- a/src/jmapNew/painter.js +++ b/src/jmapNew/painter.js @@ -6,6 +6,7 @@ import transitionDeviceStatus from './constant/stateTransition'; import shapefactory from './shape/factory'; import TransformHandle from './transformHandle'; import TransformHandleScreen from './transformHandleScreen'; +import deviceRender from './constant/deviceRender'; class Painter { constructor(jmap) { @@ -136,6 +137,8 @@ class Painter { const overlapTrainList = this.checkTrainOverlap(device); overlapTrainList.forEach((item, index) => { const trainDevice = this.$jmap.getDeviceByCode(item); + trainDevice._type = deviceRender['Train']._type; + trainDevice.zlevel = deviceRender['Train'].zlevel; trainDevice.overLapIndex = index; trainDevice.instance && this.mapInstanceLevel[deviceType.Train].remove(trainDevice.instance); this.add(trainDevice); @@ -223,7 +226,7 @@ class Painter { getShapeTipPoint(instance, opts) { if (instance) { var point = instance.getShapeTipPoint(opts); - if (point) { + if (point) { // 矩阵变换 var transPoint = instance.transformCoordToGlobal(point.x, point.y); return { diff --git a/src/jmapNew/shape/Train/index.js b/src/jmapNew/shape/Train/index.js index 477a0ef64..db5c0e5bf 100644 --- a/src/jmapNew/shape/Train/index.js +++ b/src/jmapNew/shape/Train/index.js @@ -60,7 +60,6 @@ export default class Train extends Group { this._computed(); const model = this.model; const style = this.style; - if (this.point) { this.trainB = new TrainBody({ zlevel: this.zlevel, diff --git a/src/jmapNew/theme/haerbin_01/menus/menuButton.vue b/src/jmapNew/theme/haerbin_01/menus/menuButton.vue index 411b27c86..38b15bb1f 100644 --- a/src/jmapNew/theme/haerbin_01/menus/menuButton.vue +++ b/src/jmapNew/theme/haerbin_01/menus/menuButton.vue @@ -76,9 +76,9 @@