From 999afe35bdb3a456400c715ee13f9eef1e2aa2a0 Mon Sep 17 00:00:00 2001
From: rain <1679827795@qq.com>
Date: Mon, 14 Apr 2025 09:52:34 +0800
Subject: [PATCH] 工单系统页面优化
---
src/components/map-container/mapContainer.vue | 9 ++++++---
1 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/src/components/map-container/mapContainer.vue b/src/components/map-container/mapContainer.vue
index f3238d2..c8651f0 100644
--- a/src/components/map-container/mapContainer.vue
+++ b/src/components/map-container/mapContainer.vue
@@ -41,10 +41,13 @@
([ready, detail]) => {
if (ready && detail?.location) {
const [lng, lat] = detail.location
+
if (!lng || !lat) return
+
+ let [newLng, newLat] = DC.CoordTransform.GCJ02ToWGS84(lng, lat)
window.$viewer?.zoomToPosition(new DC.Position(
- lng,
- lat,
+ newLng,
+ newLat,
1000,
0,
-90,
@@ -52,7 +55,7 @@
), () => {
})
- let point = new DC.Point(new DC.Position(lng, lat))
+ let point = new DC.Point(new DC.Position(newLng, newLat))
pointLayer.addOverlay(point)
}
},
--
Gitblit v1.9.3