jinx 8 months ago
parent
commit
7e7ef2fa89
3 changed files with 6 additions and 10 deletions
  1. 0 1
      package.json
  2. 6 4
      src/views/map/index.vue
  3. 0 5
      yarn.lock

+ 0 - 1
package.json

@@ -13,7 +13,6 @@
     "animate.css": "^4.1.1",
     "axios": "^1.9.0",
     "crypto-js": "^4.2.0",
-    "hammerjs": "^2.0.8",
     "jsonp": "^0.2.1",
     "lib-flexible": "^0.3.2",
     "markdown-it": "^14.1.0",

+ 6 - 4
src/views/map/index.vue

@@ -581,11 +581,12 @@ const setMarker = () => {
 // };
 const initMap = async () => {
   window._AMapSecurityConfig = {
-    securityJsCode: "2d0885f937e5fa6d093830e1765f593d",
+    // securityJsCode: "2d0885f937e5fa6d093830e1765f593d",
+    securityJsCode: "afcfe7885b42abca17865b2ce30c8421", //玉琦账号
   };
   const _AMap = await AMapLoader.load({
-    // key: "655ac083de961ed970f2be4ba23b3c9f", //玉骑账号
-    key: "b19c9847b3775cd993c5a8a71c5fa1a0",
+    key: "655ac083de961ed970f2be4ba23b3c9f", //玉琦账号
+    // key: "b19c9847b3775cd993c5a8a71c5fa1a0",
     version: "2.0",
     plugins: ["AMap.MoveAnimation", "AMap.ImageLayer", "AMap.TileLayer", "AMap.Geolocation", "AMap.DistrictSearch", "AMap.Driving", "AMap.Walking", "AMap.MarkerCluster", "AMap.InfoWindow"],
   });
@@ -608,7 +609,8 @@ const initMap = async () => {
   });
   map = new AMap.Map("amap", {
     viewMode: "2D",
-    mapStyle: "amap://styles/76c9ffde986e653b6c8dc2bba6a9186e", //设置地图的显示样式
+    // mapStyle: "amap://styles/76c9ffde986e653b6c8dc2bba6a9186e", //设置地图的显示样式
+    mapStyle: "amap://styles/d7b651796461dc85f1efa3c1397f61e8", //玉琦账号
     labels: true,
     zoom: 10, // 地图显示的缩放级别
     zooms: [8, 18],

+ 0 - 5
yarn.lock

@@ -1270,11 +1270,6 @@ graceful-fs@^4.1.6, graceful-fs@^4.2.0:
   resolved "https://registry.npmmirror.com/graceful-fs/-/graceful-fs-4.2.11.tgz#4183e4e8bf08bb6e05bbb2f7d2e0c8f712ca40e3"
   integrity sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==
 
-hammerjs@^2.0.8:
-  version "2.0.8"
-  resolved "https://registry.npmmirror.com/hammerjs/-/hammerjs-2.0.8.tgz#04ef77862cff2bb79d30f7692095930222bf60f1"
-  integrity sha512-tSQXBXS/MWQOn/RKckawJ61vvsDpCom87JgxiYdGwHdOa0ht0vzUWDlfioofFCRU0L+6NGDt6XzbgoJvZkMeRQ==
-
 has-symbols@^1.0.3, has-symbols@^1.1.0:
   version "1.1.0"
   resolved "https://registry.npmmirror.com/has-symbols/-/has-symbols-1.1.0.tgz#fc9c6a783a084951d0b971fe1018de813707a338"