From b3f8766818e3a8c235b648a7c406353673e76d52 Mon Sep 17 00:00:00 2001
From: 徐旺旺 <11530253@qq.com>
Date: 星期六, 08 五月 2021 11:22:35 +0800
Subject: [PATCH] 修改图层点击弹窗开关
---
src/components/LayerController/service/WmsLayerService.js | 24 ++++++++++++------------
1 files changed, 12 insertions(+), 12 deletions(-)
diff --git a/src/components/LayerController/service/WmsLayerService.js b/src/components/LayerController/service/WmsLayerService.js
index 3a2f882..8c0d5dc 100644
--- a/src/components/LayerController/service/WmsLayerService.js
+++ b/src/components/LayerController/service/WmsLayerService.js
@@ -76,9 +76,6 @@
clickListener () {
window.map.on('click', (e) => {
- if (!window.layerFactory.clickSwitch) {
- return
- }
this.featureGroup.clearLayers()
var point = this.map.latLngToContainerPoint(e.latlng, this.map.getZoom())
var size = this.map.getSize()
@@ -134,15 +131,18 @@
autoClose: false
})
.openPopup() */
- window.$layer.open({
- content: {
- content: Popup, // 缁勪欢
- data: { // 浼犻�掔殑鍙傛暟
- datas: popupDatas
- }
- },
- title: '' // 鏍囬
- })
+
+ if (window.layerFactory.clickSwitch) {
+ window.$layer.open({
+ content: {
+ content: Popup, // 缁勪欢
+ data: { // 浼犻�掔殑鍙傛暟
+ datas: popupDatas
+ }
+ },
+ title: '' // 鏍囬
+ })
+ }
// this.popupComp.setDatas(popupDatas)
// this.popupComp.setShow()
}
--
Gitblit v1.8.0