管道基础大数据平台系统开发-【前端】-新系統界面
Surpriseplus
2023-04-13 04e2c2e8f79368c462bc13c285c349cb9d387bde
src/components/ProjectOl.vue
@@ -73,11 +73,20 @@
  },
  methods: {
    initOlMap() {
      var val = 'http://{host}/LFData/2d/tiles/img/{z}/{x}/{y}.png';
      if (val.indexOf('{host}') > -1) {
        val = val.replace("{host}", iisHost)
      }
      var vectorLayer = new TileLayer({
        source: new XYZ({
          url: 'http://wprd0{1-4}.is.autonavi.com/appmaptile?lang=zh_cn&size=1&style=7&x={x}&y={y}&z={z}',
          url: val,
        }),
      });
      this.mapol = new Map({
        target: 'mapView',
        layers: [vectorLayer],