From fa05dfcce55b8589d7f76175700a92fe196dcd9b Mon Sep 17 00:00:00 2001
From: lixuliang <lixuliang_hd@126.com>
Date: 星期三, 13 三月 2024 17:59:52 +0800
Subject: [PATCH] 图层切换叠压

---
 src/utils/tool.js |   10 ++++++----
 1 files changed, 6 insertions(+), 4 deletions(-)

diff --git a/src/utils/tool.js b/src/utils/tool.js
index ae201d3..e4384d4 100644
--- a/src/utils/tool.js
+++ b/src/utils/tool.js
@@ -34,7 +34,8 @@
             tileSize: 512        
         }),
     });
-    window.mapapi.addLayer(_GLOBAL.ImageLayer);
+    // window.mapapi.addLayer(_GLOBAL.ImageLayer);
+    layersArray.insertAt(1, _GLOBAL.ImageLayer);
 }
 
 //鍔犺浇鐧借壊鍦板浘
@@ -52,7 +53,8 @@
             },
         }),
     });
-    window.mapapi.addLayer(_GLOBAL.baseMap)
+    // window.mapapi.addLayer(_GLOBAL.baseMap)
+    layersArray.insertAt(1, _GLOBAL.baseMap);
 
 }
 
@@ -65,8 +67,8 @@
             url: ` https://wprd0{1-4}.is.autonavi.com/appmaptile?lang=zh_cn&size=1&style=7&x={x}&y={y}&z={z}`,
         }),
     });
-    window.mapapi.addLayer(_GLOBAL.geoMap);
-
+    // window.mapapi.addLayer(_GLOBAL.geoMap);
+    layersArray.insertAt(1, _GLOBAL.geoMap);
 }
 
 

--
Gitblit v1.9.3