Forráskód Böngészése

feat: 关闭地图实时路况显示

sequoia tungfang 4 hete%!(EXTRA string=óta)
szülő
commit
22c14e6fa7
1 módosított fájl, 2 hozzáadás és 10 törlés
  1. 2 10
      src/components/TongzhouTrafficMap.vue

+ 2 - 10
src/components/TongzhouTrafficMap.vue

@@ -57,7 +57,7 @@ export default {
       AMap: null,
       map: null,
       infoWindow: null,
-      trafficLayer: null,
+
       routeGroups: {},
       polylines: [],
       privateStyle: {
@@ -308,7 +308,6 @@ export default {
         this.map.on('complete', () => {
           if (!this._isDestroyed) {
             this.drawStaticRoutes();
-            this.enableTrafficLayer();
           }
         });
       } catch (err) {
@@ -316,14 +315,7 @@ export default {
       }
     },
 
-    enableTrafficLayer() {
-      if (!this.isMapReady() || !this.AMap.TileLayer) return;
-      this.trafficLayer = new this.AMap.TileLayer.Traffic({
-        zIndex: 10,
-        autoRefresh: true
-      });
-      this.map.add(this.trafficLayer);
-    },
+
 
     drawStaticRoutes() {
       if (!this.isMapReady()) return;