From f7b244103e748e051537cf4b46e875acaf56c450 Mon Sep 17 00:00:00 2001
From: 徐旺旺 <11530253@qq.com>
Date: 星期三, 19 五月 2021 16:03:22 +0800
Subject: [PATCH] 重封装定位js
---
src/components/helpers/MapManager.js | 7 ++++---
1 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/src/components/helpers/MapManager.js b/src/components/helpers/MapManager.js
index 8399486..791ebe8 100644
--- a/src/components/helpers/MapManager.js
+++ b/src/components/helpers/MapManager.js
@@ -28,9 +28,10 @@
// console.log(e)
this.clearHighlight()
this.loadWfsDatas(e.latlng).then((res) => {
- console.log(res)
- highlight(res.features)
- openPropsPopup(e.latlng, res.features)
+ if (res.features.length > 0) {
+ highlight(res.features[0])
+ openPropsPopup(e.latlng, res.features)
+ }
})
})
}
--
Gitblit v1.8.0