Vue-iClient怎样加载自己绘制的iserver地图服务

0 投票
<sm-web-map :map-options="mapOptions"></sm-web-map>
<script>
export default {
  data() {
      return {
        mapOptions: {
            container: 'map', // container id
            style: {
              "version": 8,
              "sources": {
                "raster-tiles": {
                  "type": "raster",
                  "tiles": [
                    'https://iserver.supermap.io/iserver/services/map-china400/rest/maps/China/zxyTileImage.png?z={z}&x={x}&y={y}'
                  ],
                  "tileSize": 256
                }
              },
              "layers": [{
                "id": "simple-tiles",
                "type": "raster",
                "source": "raster-tiles",
                "minzoom": 0,
                "maxzoom": 22
              }]
            },
            center: [120.143, 30.236], // starting position
            zoom: 3 // starting zoom
          }
      };
}
</script>
12月 19, 2019 分类:  118次浏览 | 用户: gouxuhan (1 分)

1个回答

0 投票

VUE开发可以参考iclient开发指南,以leaflet为例

https://iclient.supermap.io/web/introduction/leafletDevelop.html#Ready

12月 19, 2019 用户: 于浩 登峰造极 (5,668 分)
...