|
@@ -321,6 +321,7 @@ import industrialTop from '@/components/IndustrialTop'
|
|
|
import znxzDetail from './ZnxzDetail.vue'
|
|
|
import znxzCompare from './ZnxzCompare.vue'
|
|
|
import L from 'leaflet'
|
|
|
+import Proj from 'proj4leaflet'
|
|
|
import ArrayQueue from '@/struct/ArrayQueue'
|
|
|
import axios from 'axios'
|
|
|
import { arcgisToGeoJSON } from '@terraformer/arcgis'
|
|
@@ -1039,38 +1040,43 @@ export default {
|
|
|
// }
|
|
|
// );
|
|
|
// this.map.addLayer(cia);
|
|
|
- let dtLayers = {
|
|
|
- name: "底图",
|
|
|
- layers: [
|
|
|
- {
|
|
|
- name: "浙江影像",
|
|
|
- id: "zjyx",
|
|
|
- checked: true,
|
|
|
- type: "wmts",
|
|
|
- url: "https://kjzl.zrzyt.zj.gov.cn/zdzy/gtkj/zjgt48/34048bffdd0d4d148ca4a40da7eade21/services/wmts/imgmap/default/oss",
|
|
|
- layername: "imgmap",
|
|
|
- },
|
|
|
- {
|
|
|
- name: "浙江注记",
|
|
|
- id: "zjzj",
|
|
|
- checked: true,
|
|
|
- type: "wmts",
|
|
|
- url: "https://zdzy.zrzyt.zj.gov.cn/gtkj/zjgt49/2003392c13044d3ab3097b0a4328ecf2/services/wmts/imgmap_lab/default/oss",
|
|
|
- layername: "imgmap_lab",
|
|
|
- },
|
|
|
- ],
|
|
|
- };
|
|
|
-
|
|
|
- var zjyx = dtLayers.layers[0];
|
|
|
- this.switchMapLayer(zjyx);
|
|
|
- var zjzj = dtLayers.layers[1];
|
|
|
- this.switchMapLayer(zjzj);
|
|
|
+ // let dtLayers = {
|
|
|
+ // name: "底图",
|
|
|
+ // layers: [
|
|
|
+ // {
|
|
|
+ // name: "浙江影像",
|
|
|
+ // id: "zjyx",
|
|
|
+ // checked: true,
|
|
|
+ // type: "wmts",
|
|
|
+ // url: "https://kjzl.zrzyt.zj.gov.cn/zdzy/gtkj/zjgt48/34048bffdd0d4d148ca4a40da7eade21/services/wmts/imgmap/default/oss",
|
|
|
+ // layername: "imgmap",
|
|
|
+ // },
|
|
|
+ // {
|
|
|
+ // name: "浙江注记",
|
|
|
+ // id: "zjzj",
|
|
|
+ // checked: true,
|
|
|
+ // type: "wmts",
|
|
|
+ // url: "https://zdzy.zrzyt.zj.gov.cn/gtkj/zjgt49/2003392c13044d3ab3097b0a4328ecf2/services/wmts/imgmap_lab/default/oss",
|
|
|
+ // layername: "imgmap_lab",
|
|
|
+ // },
|
|
|
+ // ],
|
|
|
+ // };
|
|
|
+
|
|
|
+ // var zjyx = dtLayers.layers[0];
|
|
|
+ // this.switchMapLayer(zjyx);
|
|
|
+ // var zjzj = dtLayers.layers[1];
|
|
|
+ // this.switchMapLayer(zjzj);
|
|
|
|
|
|
//定位浙江省
|
|
|
- this.location(polygons)
|
|
|
- //默认加载供地图层
|
|
|
- var gd = this.layers[0].layers[0]
|
|
|
- this.switchMapLayer(gd)
|
|
|
+ // this.location(polygons)
|
|
|
+ //默认加载所有选中图层
|
|
|
+ this.layers.forEach(layerGroup=>{
|
|
|
+ layerGroup.layers.forEach(oneLayer=>{
|
|
|
+ this.switchMapLayer(oneLayer)
|
|
|
+ })
|
|
|
+ });
|
|
|
+ // var gd = this.layers[0].layers[0]
|
|
|
+
|
|
|
},
|
|
|
//属性识别
|
|
|
mapClick(e) {
|