Browse Source

智能选址前端

liutao 2 months ago
parent
commit
422b45a5be
1 changed files with 20 additions and 11 deletions
  1. 20 11
      web_ui/src/views/industrial-land/AiIndustriaLandDetail.vue

+ 20 - 11
web_ui/src/views/industrial-land/AiIndustriaLandDetail.vue

@@ -3,7 +3,7 @@
     <div class="map-content">
       <div class="content">
         <div :id="id" class="map">
-          <div
+<div
             class="radar-scan-an"
             v-show="radarShow"
             :style="`width: ${radarScanStyle.width}; heigth: ${radarScanStyle.height}; top: ${radarScanStyle.top};left: ${radarScanStyle.left};`"
@@ -545,13 +545,13 @@ export default {
       // this.showQuery = true;
       // this.xgdk = [
       //   {
-      //     objectid: 1839,
+      //     id: 1839,
       //   },
       //   {
-      //     objectid: 1843,
+      //     id: 1843,
       //   },
       //   {
-      //     objectid: 1845,
+      //     id: 1845,
       //   },
       // ];
       // // this.xgdk = [
@@ -628,7 +628,7 @@ export default {
       }
       let that = this;
       if (dklist && dklist.length) {
-        let idGroup = dklist.map((item) => item.objectid);
+        let idGroup = dklist.map((item) => item.id);
         let sql = "(" + idGroup.join(",") + ")";
         let queryGeometryUrl = window.ApplicationConfig.queryGeometryListUrl;
         axios.get(queryGeometryUrl, { params: { items: sql } }).then((data) => {
@@ -727,7 +727,7 @@ export default {
         this.$Message.info("请输入");
         return;
       }
-      this.hotQuestionReset(this.inputText);
+      this.hotQuestionReset(this.input);
     },
     hotQuestionReset(text = "") {
       if (this.dSource === "3") {
@@ -1165,25 +1165,34 @@ export default {
               center_wkt: ele.center_wkt,
             };
           });
-
+          let geojson = wkt.parse(ele.center_wkt);
+          if (ele.tdyt.indexOf("工业")) {
+            that.getGyydWzxx(geojson.coordinates, viewObj);
+          } else {
+            that.getNoGyydWzxx(geojson.coordinates, viewObj);
+          }
           func(result);
         });
       } else if (this.dSource == "1") {
         //控制性详细规划
         layerName = "kzxxxgh";
-        idList = idList.map((ele) => ele.objectid);
+        idList = idList.map((ele) => ele.id);
         this.kgQuery(idList, (res) => {
           let result = res.map((ele) => {
             let viewObj = {
-              id: ele.objectid,
+              id: ele.id,
               name: ele.ydxz,
               tdyt: `${ele.ydxz}(${ele.yddm})`,
               dkmj: (ele.pfmarea * 0.0015).toFixed(2),
               center_wkt: ele.center_wkt,
             };
             let geojson = wkt.parse(ele.center_wkt);
-            // that.getGyydWzxx(geojson.coordinates, viewObj);
-            // that.getNoGyydWzxx(geojson.coordinates, viewObj);
+            if (ele.ydxz.indexOf("工业")>-1) {
+              that.getGyydWzxx(geojson.coordinates, viewObj);
+            } else {
+              that.getNoGyydWzxx(geojson.coordinates, viewObj);
+            }
+
             return viewObj;
           });
           func(result);