From 5dbc0728212611bcfc4fe62a3c0124a9f6428fb9 Mon Sep 17 00:00:00 2001 From: shijingjing <1789544664@qq.com> Date: Thu, 7 Jul 2022 10:04:44 +0800 Subject: [PATCH 1/5] bug --- src/apps/AppMonitoringObject/AppMonitoringObject.vue | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/apps/AppMonitoringObject/AppMonitoringObject.vue b/src/apps/AppMonitoringObject/AppMonitoringObject.vue index ce56950b..e78d4a05 100644 --- a/src/apps/AppMonitoringObject/AppMonitoringObject.vue +++ b/src/apps/AppMonitoringObject/AppMonitoringObject.vue @@ -112,6 +112,8 @@ export default { confirmTypeSelect(val) { this.status = val?.[0].value this.$nextTick(()=>{ + this.current = 1, + this.list = [] this.getList() }) }, @@ -153,7 +155,6 @@ export default { this.typelist = this.$dict.getDict('fpPrtpStatus').filter((e) => e.dictValue != 5) this.typelist.unshift({ dictName: '全部类型', dictValue: ''}) } - this.status = '' this.getListInit() From b0bca45d110dba6d011fb03db15bc5179d85d0aa Mon Sep 17 00:00:00 2001 From: yanran200730 Date: Thu, 7 Jul 2022 10:31:54 +0800 Subject: [PATCH 2/5] =?UTF-8?q?=E5=9C=B0=E5=9B=BE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../xicheng/AppMerchantMap/AppMerchantMap.vue | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/src/project/xicheng/AppMerchantMap/AppMerchantMap.vue b/src/project/xicheng/AppMerchantMap/AppMerchantMap.vue index 13bf52e5..6581f829 100644 --- a/src/project/xicheng/AppMerchantMap/AppMerchantMap.vue +++ b/src/project/xicheng/AppMerchantMap/AppMerchantMap.vue @@ -32,8 +32,7 @@ polygons: [], labels: [], businessName: '', - ops: { - }, + ops: {}, markers: [], isShow: false, MarkerCluster: null, @@ -61,9 +60,9 @@ this.isShow = false this.map.easeTo({ center: new this.lib.LatLng(item.lat, item.lng), - zoom: 17 + zoom: 20 }, { - duration: 2000 + duration: 800 }) }, @@ -155,8 +154,6 @@ } } - // this.config.latlng && map.setCenter(this.config.latlng) - this.MarkerCluster = new TMap.MarkerCluster({ map, gridSize: 60, enableDefaultStyle: false, // 关闭默认样式 @@ -166,7 +163,8 @@ content: `${e.name}`, properties: {...e} })) || [], - zoomOnClick: true + zoomOnClick: true, + maxZoom: 18 }) this.setCenter(points.map(e => { return new TMap.LatLng(e.lat, e.lng) From a1e18f7c8bcdd6df9d504e376f94c1dbf582c63c Mon Sep 17 00:00:00 2001 From: yanran200730 Date: Thu, 7 Jul 2022 11:09:45 +0800 Subject: [PATCH 3/5] =?UTF-8?q?=E5=9C=B0=E5=9B=BE=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../xicheng/AppMerchantMap/AppMerchantMap.vue | 36 +++++++++++++++++-- 1 file changed, 33 insertions(+), 3 deletions(-) diff --git a/src/project/xicheng/AppMerchantMap/AppMerchantMap.vue b/src/project/xicheng/AppMerchantMap/AppMerchantMap.vue index 6581f829..87b31715 100644 --- a/src/project/xicheng/AppMerchantMap/AppMerchantMap.vue +++ b/src/project/xicheng/AppMerchantMap/AppMerchantMap.vue @@ -60,10 +60,17 @@ this.isShow = false this.map.easeTo({ center: new this.lib.LatLng(item.lat, item.lng), - zoom: 20 + zoom: 23 }, { duration: 800 }) + + setTimeout(() => { + document.querySelectorAll('.marker').forEach(e => { + e.classList.remove('marker-active') + }) + document.querySelector(`.marker-${item.id}`).classList.add('marker-active') + }, 900) }, getList (isSearch) { @@ -114,6 +121,7 @@ onInit(options) { this.content = options.content; this.position = options.position; + this.markersId = options.markersId this.customClass = options.customClass }; @@ -125,6 +133,9 @@ createDOM() { let dom = document.createElement('div'); dom.classList.add(this.customClass || 'marker'); + if (this.markersId) { + dom.classList.add(this.markersId); + } dom.innerText = this.content; // 监听点击事件,实现zoomOnClick @@ -164,7 +175,7 @@ properties: {...e} })) || [], zoomOnClick: true, - maxZoom: 18 + maxZoom: 20 }) this.setCenter(points.map(e => { return new TMap.LatLng(e.lat, e.lng) @@ -196,7 +207,7 @@ } else { //点标记样式 let {content, id} = item.geometries?.[0] || {}, - overlay = new ClusterBubble({map, position: item.center, content}) + overlay = new ClusterBubble({map, position: item.center, content, markersId: `marker-${id}`}) overlay.on('click', () => { uni.navigateTo({ url: `../AppMerchantManage/detail?id=${id}` @@ -367,6 +378,7 @@ width: fit-content; height: 56px; border-radius: 52px; + z-index: 1; transform: translate(-50%, -50%); display: flex; align-items: center; @@ -383,6 +395,24 @@ border: 12px solid transparent; border-top-color: #558BFE; } + + &.marker-active { + z-index: 11; + background: red; + + &:before { + content: " "; + display: block; + position: absolute; + bottom: 0; + left: 50%; + width: 0; + height: 0; + transform: translate(-50%, 100%); + border: 12px solid transparent; + border-top-color: red; + } + } } * { From d6038f101509939845a42f2c1ad131ad77caed87 Mon Sep 17 00:00:00 2001 From: yanran200730 Date: Thu, 7 Jul 2022 14:26:55 +0800 Subject: [PATCH 4/5] =?UTF-8?q?=E4=BC=98=E5=8C=96=E5=9C=B0=E5=9B=BE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/project/xicheng/AppMerchantMap/AppMerchantMap.vue | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/src/project/xicheng/AppMerchantMap/AppMerchantMap.vue b/src/project/xicheng/AppMerchantMap/AppMerchantMap.vue index 87b31715..bf76b7ea 100644 --- a/src/project/xicheng/AppMerchantMap/AppMerchantMap.vue +++ b/src/project/xicheng/AppMerchantMap/AppMerchantMap.vue @@ -58,19 +58,15 @@ this.businessName = item.businessName this.isShow = false - this.map.easeTo({ - center: new this.lib.LatLng(item.lat, item.lng), - zoom: 23 - }, { - duration: 800 - }) + this.map.setCenter(new this.lib.LatLng(item.lat, item.lng)) + this.map.setZoom(22) setTimeout(() => { document.querySelectorAll('.marker').forEach(e => { e.classList.remove('marker-active') }) document.querySelector(`.marker-${item.id}`).classList.add('marker-active') - }, 900) + }, 400) }, getList (isSearch) { From bbd55b25c7c13391c4d1aaa89668195e864a106a Mon Sep 17 00:00:00 2001 From: yanran200730 Date: Thu, 7 Jul 2022 14:44:32 +0800 Subject: [PATCH 5/5] =?UTF-8?q?=E5=9C=B0=E5=9B=BE=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/project/xicheng/AppMerchantMap/AppMerchantMap.vue | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/project/xicheng/AppMerchantMap/AppMerchantMap.vue b/src/project/xicheng/AppMerchantMap/AppMerchantMap.vue index bf76b7ea..7837a999 100644 --- a/src/project/xicheng/AppMerchantMap/AppMerchantMap.vue +++ b/src/project/xicheng/AppMerchantMap/AppMerchantMap.vue @@ -171,7 +171,7 @@ properties: {...e} })) || [], zoomOnClick: true, - maxZoom: 20 + maxZoom: 18 }) this.setCenter(points.map(e => { return new TMap.LatLng(e.lat, e.lng) @@ -368,6 +368,7 @@ } ::v-deep.marker { + position: relative; color: #fff; background: #558BFE; padding: 0 32px;