|
@@ -745,17 +745,41 @@ export default {
|
|
|
if (title == "分层分户" || title == "8号楼-谷") {
|
|
|
let id = handModel(movement);
|
|
|
} else {
|
|
|
- handnew(movement);
|
|
|
+ handnew(movement,(id)=> this.getFenCengFenHu(id,store.state.checkedData));
|
|
|
}
|
|
|
+ // let newArr = [];
|
|
|
+ // GetHouseInfo({ id: "2c01647f-4533-4472-b20b-f5caa4c705b0" }).then(
|
|
|
+ // (res) => {
|
|
|
+ // for (const [key, value] of Object.entries(res.data)) {
|
|
|
+ // newArr.push({ name: keyName[key], value: value });
|
|
|
+ // }
|
|
|
+ // this.addLayerList(title);
|
|
|
+ // this.queryResults[this.activeLayerId] = [newArr];
|
|
|
+ // this.queryResultsGeom[this.activeLayerId] = [];
|
|
|
+ // }
|
|
|
+ // );
|
|
|
+ },
|
|
|
+ getFenCengFenHu(id, obj) {
|
|
|
let newArr = [];
|
|
|
- GetHouseInfo({ id: "2c01647f-4533-4472-b20b-f5caa4c705b0" }).then(
|
|
|
+ let queryByIDPar = {
|
|
|
+ getFeatureMode: "SQL",
|
|
|
+ datasetNames: [`${obj.fwgzkj}:${obj.fwmc}`],
|
|
|
+ queryParameter: { attributeFilter: `ID=\"${id}\"` }
|
|
|
+ };
|
|
|
+ let url2 = calcIserverURI(obj.url).replace("3D-", "data-");
|
|
|
+ mapQuery(url2, queryByIDPar).then(
|
|
|
+
|
|
|
(res) => {
|
|
|
- for (const [key, value] of Object.entries(res.data)) {
|
|
|
- newArr.push({ name: keyName[key], value: value });
|
|
|
+ if (res && res.totalCount > 0) {
|
|
|
+ let feature = res.features[0];
|
|
|
+ console.log(res, "res");
|
|
|
+ feature.fieldNames.forEach((fieldName, i) => {
|
|
|
+ newArr.push({ name: fieldName, value: feature.fieldValues[i] });
|
|
|
+ });
|
|
|
+ this.addLayerList(obj.title);
|
|
|
+ this.queryResults[this.activeLayerId] = [newArr];
|
|
|
+ this.queryResultsGeom[this.activeLayerId] = [];
|
|
|
}
|
|
|
- this.addLayerList(title);
|
|
|
- this.queryResults[this.activeLayerId] = [newArr];
|
|
|
- this.queryResultsGeom[this.activeLayerId] = [];
|
|
|
}
|
|
|
);
|
|
|
},
|