|
@@ -33,6 +33,8 @@
|
|
|
@click="eitem.isshow = !eitem.isshow"
|
|
|
></div>
|
|
|
</div>
|
|
|
+ <div>{{ i == 1 ? eitem : "" }}</div>
|
|
|
+
|
|
|
<scjgContent
|
|
|
:ref="`contentRef${eitem.id}`"
|
|
|
v-show="eitem.isshow"
|
|
@@ -52,7 +54,7 @@
|
|
|
import scjgContent from "../../complianceAnalysis/components/scjgContent.vue";
|
|
|
// import collRecursiveTree from "./collRecursiveTree.vue";
|
|
|
import { getyjjg } from "@/api/stxf/tdzz.js";
|
|
|
-
|
|
|
+import {jslist} from "./config.js";
|
|
|
import parse from "wellknown";
|
|
|
let dataSourceList = {};
|
|
|
let colors = [
|
|
@@ -76,43 +78,7 @@ export default {
|
|
|
},
|
|
|
data() {
|
|
|
return {
|
|
|
- echarts: [
|
|
|
- {
|
|
|
- id: "QHBH",
|
|
|
- label: "整治前后土地利用结构变化",
|
|
|
- dataList: [],
|
|
|
- iseyes: false,
|
|
|
- isshow: true,
|
|
|
- scxstyle: 2,
|
|
|
- },
|
|
|
- {
|
|
|
- id: "XZGD",
|
|
|
- label: "新增耕地",
|
|
|
- dataList: [],
|
|
|
- iseyes: false,
|
|
|
- isshow: true,
|
|
|
- scxstyle: 3,
|
|
|
- area: 0,
|
|
|
- area2: 0,
|
|
|
- },
|
|
|
- {
|
|
|
- id: "SQSX",
|
|
|
- label: "三线分析",
|
|
|
- dataList: [],
|
|
|
-
|
|
|
- iseyes: false,
|
|
|
- isshow: true,
|
|
|
- scxstyle: 0,
|
|
|
- },
|
|
|
- {
|
|
|
- id: "GHDK",
|
|
|
- label: "详细规划分析",
|
|
|
- dataList: [],
|
|
|
- iseyes: false,
|
|
|
- isshow: true,
|
|
|
- scxstyle: 0,
|
|
|
- },
|
|
|
- ],
|
|
|
+ echarts: [],
|
|
|
ruleForm: {
|
|
|
name: "",
|
|
|
xzmj: "",
|
|
@@ -156,26 +122,24 @@ export default {
|
|
|
jdData.result[0].push(ci.zzq_area);
|
|
|
jdData.result[1].push(ci.zzh_area);
|
|
|
jdData.result[2].push(ci.ce_area);
|
|
|
+ // zzh_geom
|
|
|
});
|
|
|
this.setEchart(jdData, "QHBH");
|
|
|
res.data.SQSX.map((ci) => {
|
|
|
ci.name = ci.yzBsm;
|
|
|
ci.value = ci.sumvalue;
|
|
|
- ci.geom = ci.geomvalue || "";
|
|
|
});
|
|
|
res.data.GHDK.map((ci) => {
|
|
|
ci.name = ci.groupvalue;
|
|
|
ci.value = ci.sumvalue;
|
|
|
- ci.geom = ci.geomvalue || "";
|
|
|
});
|
|
|
-
|
|
|
- this.echarts[0].dataList = res.data ["3D"];
|
|
|
- this.echarts[1].dataList = res.data.GHDK;
|
|
|
- this.echarts[1].area = 20;
|
|
|
- this.echarts[1].area2 = 0;
|
|
|
- this.echarts[2].dataList = res.data.SQSX;
|
|
|
- this.echarts[3].dataList = res.data.GHDK;
|
|
|
|
|
|
+ this.echarts[0].dataList = res.data["3D"];
|
|
|
+ this.echarts[1].dataList = res.data.XZGD || [{}];
|
|
|
+ this.echarts[2].dataList = res.data.SQSX || [];
|
|
|
+ this.echarts[3].dataList = res.data.GHDK || [];
|
|
|
+ this.$set(this, "echarts", this.echarts);
|
|
|
+ // console.log(this., "this.echarts");
|
|
|
this.setEchart(res.data.SQSX, "SQSX");
|
|
|
this.setEchart(res.data.GHDK, "GHDK");
|
|
|
this.$emit("updateParent", "loading", false);
|
|
@@ -198,9 +162,10 @@ export default {
|
|
|
let iseyes = this.echarts[i].iseyes;
|
|
|
if (this.echarts[i].dataList)
|
|
|
this.echarts[i].dataList.forEach((child, ci) => {
|
|
|
+ console.log(child, "child");
|
|
|
this.changeDataSources({ ...child, iseyes }, colors[ci]);
|
|
|
});
|
|
|
- this.lForEach(this.echarts[i].lchildren, "sources", iseyes);
|
|
|
+ // this.lForEach(this.echarts[i].lchildren, "sources", iseyes);
|
|
|
// }
|
|
|
// emit("eyesChaneg");
|
|
|
},
|
|
@@ -232,14 +197,15 @@ export default {
|
|
|
}
|
|
|
});
|
|
|
},
|
|
|
- changeDataSources({ geom, id, iseyes, iszoom }, color) {
|
|
|
+ changeDataSources({ geomvalue, id, iseyes, iszoom }, color) {
|
|
|
+ console.log(geomvalue, id, iseyes, iszoom, color);
|
|
|
if (iszoom) {
|
|
|
- this.zoomTo(id, geom);
|
|
|
+ this.zoomTo(id, geomvalue);
|
|
|
} else if (dataSourceList[id]) {
|
|
|
dataSourceList[id].show = iseyes;
|
|
|
this.tempdataSourcesId = null;
|
|
|
- } else if (geom) {
|
|
|
- this.addPolygon(geom, id, color);
|
|
|
+ } else if (geomvalue) {
|
|
|
+ this.addPolygon(geomvalue, id, color);
|
|
|
}
|
|
|
},
|
|
|
zoomTo(id, geom) {
|
|
@@ -322,6 +288,12 @@ export default {
|
|
|
reset() {
|
|
|
if (Object.keys(dataSourceList).length) viewer.dataSources.removeAll();
|
|
|
dataSourceList = {};
|
|
|
+ this.sertlist();
|
|
|
+ },
|
|
|
+ sertlist() {
|
|
|
+ this.echarts = [
|
|
|
+
|
|
|
+ ];
|
|
|
},
|
|
|
},
|
|
|
|