|
|
@ -129,8 +129,25 @@ export default { |
|
|
|
// Vue.prototype.map2d = this.$refs.gisMap2d; |
|
|
|
Vue.prototype.mapIns = this.$refs.gisMap2d; |
|
|
|
this.isGisCompleted = true; |
|
|
|
|
|
|
|
this.$root.$on('refresh-gismap', this.refreshLayer); |
|
|
|
}, |
|
|
|
methods: { |
|
|
|
refreshLayer(layers){ |
|
|
|
console.log(layers,'更新图标') |
|
|
|
this.$refs.gisMap2d.addPointByArr( |
|
|
|
{pointList:[]}, // 点位数据数组(按以下规范组装) |
|
|
|
'jhlayers', // 当前添加的数据 唯一标识(删除该图层时也会用到)//./事件专题/交通事故.svg |
|
|
|
true // 当前新加图层是否启用聚合效果 |
|
|
|
); |
|
|
|
this.$refs.gisMap2d.removeLayerByName('jhlayers'); |
|
|
|
this.$refs.gisMap2d.addPointByArr( |
|
|
|
layers, |
|
|
|
"jhlayers", |
|
|
|
true |
|
|
|
); |
|
|
|
|
|
|
|
}, |
|
|
|
debug(){ |
|
|
|
this.$refs.Thumbnail.debug() |
|
|
|
}, |
|
|
@ -157,15 +174,15 @@ export default { |
|
|
|
this.$refs.gisMap2d.addPointByArr( |
|
|
|
// this.pointsObj, |
|
|
|
pointsObj_new, |
|
|
|
"customLayer111", |
|
|
|
"jhlayers", |
|
|
|
true |
|
|
|
); |
|
|
|
}, |
|
|
|
ccccc() { |
|
|
|
this.$refs.gisMap2d.removeLayerByName("customLayer111"); |
|
|
|
this.$refs.gisMap2d.removeLayerByName("jhlayers"); |
|
|
|
}, |
|
|
|
ddddd() { |
|
|
|
this.$refs.gisMap2d.pileIsShow("customLayer111", this.isShow); |
|
|
|
this.$refs.gisMap2d.pileIsShow("jhlayers", this.isShow); |
|
|
|
// this.$refs.gisMap2d.pileIsShow("customLayer222", this.isShow); |
|
|
|
this.isShow = !this.isShow; |
|
|
|
}, |
|
|
|