|
@@ -139,7 +139,7 @@ export default {
|
|
|
this.echarts[i].dataList.forEach((child, ci) => {
|
|
|
this.changeDataSources({ ...child, iseyes }, colors[ci]);
|
|
|
});
|
|
|
- this.lForEach(this.echarts[i].lchildren, iseyes, "sources");
|
|
|
+ this.lForEach(this.echarts[i].lchildren, "sources", iseyes);
|
|
|
// }
|
|
|
// emit("eyesChaneg");
|
|
|
},
|
|
@@ -171,13 +171,18 @@ export default {
|
|
|
}
|
|
|
});
|
|
|
},
|
|
|
- changeDataSources({ geom, id, iseyes }, color) {
|
|
|
- if (dataSourceList[id]) {
|
|
|
+ changeDataSources({ geom, id, iseyes, iszoom }, color) {
|
|
|
+ if (iszoom) {
|
|
|
+ this.zoomTo(id);
|
|
|
+ } else if (dataSourceList[id]) {
|
|
|
dataSourceList[id].show = iseyes;
|
|
|
} else if (geom) {
|
|
|
this.addPolygon(geom, id, color);
|
|
|
}
|
|
|
},
|
|
|
+ zoomTo(id) {
|
|
|
+ if (dataSourceList[id]) viewer.zoomTo(dataSourceList[id]);
|
|
|
+ },
|
|
|
setEchart(data, id, childid) {
|
|
|
this.$nextTick(() => {
|
|
|
let type = data.length <= 6 ? "horizontal" : "vertical";
|