|
|
@@ -178,37 +178,43 @@ export default {
|
|
|
pageSize: this.pageSize,
|
|
|
jcbh: this.input,
|
|
|
};
|
|
|
- // if (show)
|
|
|
- // JctbList({ ...obj, pageNum: 1, pageSize: 999999999 }).then((res) => {
|
|
|
- // this.active_dableData = res.rows;
|
|
|
- // });
|
|
|
+ if (show)
|
|
|
+ JctbList({ ...obj, pageNum: 1, pageSize: 999999999 }).then((res) => {
|
|
|
+ // this.active_dableData = res.rows;
|
|
|
+ this.toMap(res.rows);
|
|
|
+ });
|
|
|
JctbList(obj).then((res) => {
|
|
|
this.tableData = res.rows;
|
|
|
this.total = res.total;
|
|
|
- let ewkt = [];
|
|
|
- removeGeoJSON("farmlandjc");
|
|
|
- res.rows.forEach((item) => {
|
|
|
- ewkt.push(item.geom);
|
|
|
- if (item.geom)
|
|
|
- loadGeoJSON(
|
|
|
- item.geom,
|
|
|
- "#55A1E3",
|
|
|
- {},
|
|
|
- (data) => (data.name = "farmlandjc")
|
|
|
- );
|
|
|
- });
|
|
|
- ewktToenvelope({ ewkt }).then((res) => {
|
|
|
- loadGeoJSON(
|
|
|
- res.data,
|
|
|
- "#55A1E3",
|
|
|
- {
|
|
|
- isfly: true,
|
|
|
- fill_a: 0.01,
|
|
|
- sw: 0.001,
|
|
|
- },
|
|
|
- (data) => (data.name = "farmlandjc")
|
|
|
- );
|
|
|
- });
|
|
|
+ // this.toMap(res.rows);
|
|
|
+ });
|
|
|
+ },
|
|
|
+ toMap(maplist) {
|
|
|
+ let ewkt = [];
|
|
|
+ removeGeoJSON("farmlandjc");
|
|
|
+ maplist.forEach((item) => {
|
|
|
+ ewkt.push(item.geom);
|
|
|
+ if (item.geom) {
|
|
|
+ item.type = "图斑上图";
|
|
|
+ loadGeoJSON(item.geom, "#ff0000", {}, (data) => {
|
|
|
+ data.name = "farmlandjc";
|
|
|
+ data.entities.values.forEach((entity) => {
|
|
|
+ entity.properties = item;
|
|
|
+ });
|
|
|
+ });
|
|
|
+ }
|
|
|
+ });
|
|
|
+ ewktToenvelope({ ewkt }).then((res) => {
|
|
|
+ loadGeoJSON(
|
|
|
+ res.data,
|
|
|
+ "#43EDED",
|
|
|
+ {
|
|
|
+ isfly: true,
|
|
|
+ fill_a: 0.01,
|
|
|
+ sw: 0.001,
|
|
|
+ },
|
|
|
+ (data) => (data.name = "farmlandjc")
|
|
|
+ );
|
|
|
});
|
|
|
},
|
|
|
handleClick(item) {
|
|
|
@@ -220,7 +226,7 @@ export default {
|
|
|
this.tempdataLayerId = "h_" + item.index;
|
|
|
loadGeoJSON(
|
|
|
item.geom,
|
|
|
- "#ff0000",
|
|
|
+ "#43EDED",
|
|
|
{ isfly: true, sw: 5 },
|
|
|
(data) => {
|
|
|
let mul = "HORIZONTAL";
|
|
|
@@ -265,28 +271,11 @@ export default {
|
|
|
});
|
|
|
});
|
|
|
},
|
|
|
- async init(params) {
|
|
|
- const that = this;
|
|
|
- let obj = {
|
|
|
- jscType: "jsc_bjxm_csbj_zbmx",
|
|
|
- beginTime: "2024-01-01",
|
|
|
- endTime: "2024-12-04",
|
|
|
- id: "4602",
|
|
|
- ...params,
|
|
|
- };
|
|
|
- let data = await QueryList(obj);
|
|
|
- data.data.map((res) => {
|
|
|
- if (res.geom) {
|
|
|
- res.geom = wellknown.parse(res.geom.split(";")[1]);
|
|
|
- }
|
|
|
- });
|
|
|
- this.active_dableData = data.data;
|
|
|
- },
|
|
|
},
|
|
|
watch: {
|
|
|
updateObj: {
|
|
|
handler(newVal, oldVal) {
|
|
|
- this.initNew();
|
|
|
+ this.initNew(true);
|
|
|
},
|
|
|
deep: true,
|
|
|
// immediate: true,
|
|
|
@@ -294,21 +283,7 @@ export default {
|
|
|
// input(newVal, oldVal){
|
|
|
// this.initNew();
|
|
|
// },
|
|
|
- active_dableData(newVal, oldVal) {
|
|
|
- viewer.dataSources.removeAll();
|
|
|
- viewer.entities.removeAll();
|
|
|
- newVal.forEach((res, index) => {
|
|
|
- res.type = "图斑上图";
|
|
|
- res.index = index;
|
|
|
- if (res.geom)
|
|
|
- loadGeoJSON(res.geom, "#55A1E3", {}, (data) => {
|
|
|
- layerSources[index] = data;
|
|
|
- data.entities.values.forEach((entity) => {
|
|
|
- entity.properties = res;
|
|
|
- });
|
|
|
- });
|
|
|
- });
|
|
|
- },
|
|
|
+
|
|
|
tempdataLayerId(newVal, oldVal) {
|
|
|
// if (oldVal && tdsy.layersObj[oldVal]) {
|
|
|
// tdsy.layersObj[oldVal].show = false;
|
|
|
@@ -379,5 +354,14 @@ export default {
|
|
|
// border-bottom: none !important;
|
|
|
// border-bottom: transparent !important;
|
|
|
// }
|
|
|
+ // .handle{
|
|
|
+ // background: rgba(45, 140, 240, 0.2);
|
|
|
+ // }
|
|
|
+ /deep/ .el-table td.el-table__cell,
|
|
|
+ .el-table th.el-table__cell.is-leaf {
|
|
|
+ background: rgba(10, 25, 38, 1) !important;
|
|
|
+
|
|
|
+ border-bottom: 0px solid #ebeef5;
|
|
|
+ }
|
|
|
}
|
|
|
</style>
|