From a8b3f0c6e4b19644510d8efeb7f837e50b370c06 Mon Sep 17 00:00:00 2001
From: Surpriseplus <845948745@qq.com>
Date: 星期日, 26 二月 2023 16:59:38 +0800
Subject: [PATCH] 管道分析定位效果修改,

---
 src/views/Tools/pipeLineAnaly.vue |  150 +++++++++++++++++++++++++++++--------
 src/assets/lang/zh.js             |   16 ++--
 src/views/Synthesis/LeftMenu.vue  |    3 
 src/assets/lang/en.js             |   16 ++--
 src/views/Tools/queryinfo.vue     |   17 ++-
 5 files changed, 144 insertions(+), 58 deletions(-)

diff --git a/src/assets/lang/en.js b/src/assets/lang/en.js
index 7baf267..d301641 100644
--- a/src/assets/lang/en.js
+++ b/src/assets/lang/en.js
@@ -53,13 +53,13 @@
 
   dataManage: {
     dataManage: 'Data Manage',
-    catalogueManage: 'catalogueManage',
+    catalogueManage: 'project management',
     dataUpdata: 'dataUpdata',
     datawarehousing: 'Data warehousing',
     rangeManage: 'Range management',
     dataRetrieval: 'data retrieval',
     dataDownload: 'Data download',
-    projectManage: 'project management',
+    projectManage: 'Project information',
     dataStatistics: 'data Statistics',
     dataStaticObj: {
       type1: 'Primary module',
@@ -850,12 +850,12 @@
       Histogram: "Histogram",
       Download: "Download",
     },
-    lable1:"Please enter a name",
-    lable2:"Please enter a data name",
-    lable3:"Please enter a table name",
-    lable4:"Please enter a domain name",
-    lable5:"Please enter a version name",
-    lable6:"Advanced queries",
+    lable1: "Please enter a name",
+    lable2: "Please enter a data name",
+    lable3: "Please enter a table name",
+    lable4: "Please enter a domain name",
+    lable5: "Please enter a version name",
+    lable6: "Advanced queries",
 
 
 
diff --git a/src/assets/lang/zh.js b/src/assets/lang/zh.js
index f7ba299..59c3b46 100644
--- a/src/assets/lang/zh.js
+++ b/src/assets/lang/zh.js
@@ -52,13 +52,13 @@
   },
   dataManage: {
     dataManage: '鏁版嵁绠$悊',
-    catalogueManage: '鐩綍绠$悊',
+    catalogueManage: '椤圭洰绠$悊',
     dataUpdata: '鏁版嵁涓婁紶',
     datawarehousing: '鏁版嵁鍏ュ簱',
     rangeManage: '鍊煎煙绠$悊',
     dataRetrieval: '鏁版嵁妫�绱�',
     dataDownload: '鏁版嵁涓嬭浇',
-    projectManage: '椤圭洰绠$悊',
+    projectManage: '椤圭洰淇℃伅',
     dataStatistics: '鏁版嵁缁熻',
     dataStaticObj: {
       type1: '鏈嶅姟鍚嶇О',
@@ -861,12 +861,12 @@
       Histogram: "鏌辩姸鍥�",
       Download: "涓嬭浇",
     },
-    lable1:"璇疯緭鍏ュ悕绉�",
-    lable2:"璇疯緭鍏ユ暟鎹悕绉�",
-    lable3:"璇疯緭鍏ヨ〃鍚嶇О",
-    lable4:"璇疯緭鍏ュ�煎煙鍚嶇О",
-    lable5:"璇疯緭鍏ョ増鏈悕绉�",
-    lable6:"楂樼骇鏌ヨ",
+    lable1: "璇疯緭鍏ュ悕绉�",
+    lable2: "璇疯緭鍏ユ暟鎹悕绉�",
+    lable3: "璇疯緭鍏ヨ〃鍚嶇О",
+    lable4: "璇疯緭鍏ュ�煎煙鍚嶇О",
+    lable5: "璇疯緭鍏ョ増鏈悕绉�",
+    lable6: "楂樼骇鏌ヨ",
 
 
 
diff --git a/src/views/Synthesis/LeftMenu.vue b/src/views/Synthesis/LeftMenu.vue
index 81d4aa5..82ac12e 100644
--- a/src/views/Synthesis/LeftMenu.vue
+++ b/src/views/Synthesis/LeftMenu.vue
@@ -1264,8 +1264,7 @@
                 close: () => {
                   if (this.$store.state.pipelineEntity.length != 0) {
                     for (var i in this.$store.state.pipelineEntity) {
-                      var item = this.$store.state.pipelineEntity[i];
-                      sgworld.Viewer.entities.remove(item);
+                      sgworld.Viewer.entities.remove(this.$store.state.pipelineEntity[i]);
                     }
                   }
                 },
diff --git a/src/views/Tools/pipeLineAnaly.vue b/src/views/Tools/pipeLineAnaly.vue
index 05cabd3..4e4b7f9 100644
--- a/src/views/Tools/pipeLineAnaly.vue
+++ b/src/views/Tools/pipeLineAnaly.vue
@@ -2,7 +2,11 @@
   <div class="pipeLineBox">
     <div class="headerBox">
       <div class="elFrom">
-        <el-form ref="form" :model="ruleFrom" label-width="120px">
+        <el-form
+          ref="form"
+          :model="ruleFrom"
+          label-width="120px"
+        >
           <el-form-item label="绠¢亾涓績绾�">
             <el-select
               @change="selectChange"
@@ -54,13 +58,15 @@
         </div>
         <div class="transInfo">
           <div>
-            <el-link @click="setTransRight" :underline="false"
-              ><i class="el-icon-d-arrow-right"></i
-            ></el-link>
+            <el-link
+              @click="setTransRight"
+              :underline="false"
+            ><i class="el-icon-d-arrow-right"></i></el-link>
             <br />
-            <el-link @click="setTransLeft" :underline="false"
-              ><i class="el-icon-d-arrow-left"></i
-            ></el-link>
+            <el-link
+              @click="setTransLeft"
+              :underline="false"
+            ><i class="el-icon-d-arrow-left"></i></el-link>
           </div>
         </div>
         <div class="transBox">
@@ -82,8 +88,14 @@
       </div>
       <div class="sureButton">
         <div class="suerBox">
-          <el-button @click="setAnalysis" size="small">鍒嗘瀽</el-button>
-          <el-button @click="clearAnalysis" size="small">鍙栨秷</el-button>
+          <el-button
+            @click="setAnalysis"
+            size="small"
+          >鍒嗘瀽</el-button>
+          <el-button
+            @click="clearAnalysis"
+            size="small"
+          >鍙栨秷</el-button>
         </div>
       </div>
     </div>
@@ -102,9 +114,11 @@
 
       <div class="contentLeft">
         <div style="float: right; padding: 2px">
-          <el-button @click="showDialogVivable()" size="small" type="info"
-            >涓嬭浇</el-button
-          >
+          <el-button
+            @click="showDialogVivable()"
+            size="small"
+            type="info"
+          >涓嬭浇</el-button>
           <!-- <el-button
             size="mini"
             type="info"
@@ -114,14 +128,22 @@
             type="info"
           >鍒犻櫎</el-button> -->
         </div>
-        <el-table :data="tableData" style="width: 100%" height="70%">
+        <el-table
+          :data="tableData"
+          style="width: 100%"
+          height="70%"
+        >
           <el-table-column
             align="center"
             type="index"
             :label="$t('operatManage.ELM.index')"
             width="70px"
           />
-          <el-table-column label="瀹氫綅" width="100" align="center">
+          <el-table-column
+            label="瀹氫綅"
+            width="100"
+            align="center"
+          >
             <template slot-scope="scope">
               <el-button
                 icon="el-icon-map-location"
@@ -130,18 +152,41 @@
               ></el-button>
             </template>
           </el-table-column>
-          <el-table-column prop="acrossName" label="琚┛瓒婂湴鐗╁悕绉�" width="180">
+          <el-table-column
+            prop="acrossName"
+            label="琚┛瓒婂湴鐗╁悕绉�"
+            width="180"
+          >
           </el-table-column>
-          <el-table-column prop="acrossLength" label="绌胯秺闀垮害" width="100">
+          <el-table-column
+            prop="acrossLength"
+            label="绌胯秺闀垮害"
+            width="100"
+          >
           </el-table-column>
-          <el-table-column prop="pipeName" label="绠$嚎鍚嶇О" width="180">
+          <el-table-column
+            prop="pipeName"
+            label="绠$嚎鍚嶇О"
+            width="180"
+          >
           </el-table-column>
-          <el-table-column prop="segName" label="绠℃鍚嶇О" width="180">
+          <el-table-column
+            prop="segName"
+            label="绠℃鍚嶇О"
+            width="180"
+          >
           </el-table-column>
-          <el-table-column prop="remarks" label="澶囨敞" width="100">
+          <el-table-column
+            prop="remarks"
+            label="澶囨敞"
+            width="100"
+          >
           </el-table-column>
         </el-table>
-        <div class="pagination_box" style="margin-top: 10px">
+        <div
+          class="pagination_box"
+          style="margin-top: 10px"
+        >
           <el-pagination
             @size-change="handleSizeChange"
             @current-change="handleCurrentChange"
@@ -171,14 +216,20 @@
         label-width="100px"
         class="codeForm"
       >
-        <el-form-item :label="$t('common.passworld')" prop="password">
+        <el-form-item
+          :label="$t('common.passworld')"
+          prop="password"
+        >
           <el-input
             type="password"
             v-model="codeForm.password"
             show-password
           ></el-input>
         </el-form-item>
-        <el-form-item :label="$t('common.SPassword')" prop="repassword">
+        <el-form-item
+          :label="$t('common.SPassword')"
+          prop="repassword"
+        >
           <el-input
             type="password"
             v-model="codeForm.repassword"
@@ -186,10 +237,18 @@
           ></el-input>
         </el-form-item>
         <el-form-item>
-          <el-button type="info" size="small" @click="download">{{
+          <el-button
+            type="info"
+            size="small"
+            @click="download"
+          >{{
             $t("common.confirm")
           }}</el-button>
-          <el-button type="info" size="small" @click="closeDialog">{{
+          <el-button
+            type="info"
+            size="small"
+            @click="closeDialog"
+          >{{
             $t("common.cancel")
           }}</el-button>
         </el-form-item>
@@ -343,16 +402,39 @@
       }
     },
     setShowImagePoint(res) {
-      var obj = { X: res[0], Y: res[1], Altitude: 1000 };
-      var imageLabel = sgworld.Creator.CreateImageLabel(
-        obj,
-        SmartEarthRootUrl + "Workers/image/mark.png",
-        {},
-        0,
-        "绠¢亾绌洪棿鍒嗘瀽"
+      // var obj = { X: res[0], Y: res[1], Altitude: 1000 };
+      // var imageLabel = sgworld.Creator.CreateImageLabel(
+      //   obj,
+      //   SmartEarthRootUrl + "Workers/image/mark.png",
+      //   {},
+      //   0,
+      //   "绠¢亾绌洪棿鍒嗘瀽"
+      // );
+      var val = Cesium.Cartesian3.fromDegrees(
+        res[0],
+        res[1]
       );
-      this.$store.state.pipelineEntity.push(imageLabel.item);
-      sgworld.Navigate.flyToObj(imageLabel.item);
+      var point = Viewer.entities.add({
+        position: val,
+        billboard: {
+          // 鍥惧儚鍦板潃锛孶RI鎴朇anvas鐨勫睘鎬�
+          image: SmartEarthRootUrl + "Workers/image/mark.png",
+          heightReference: Cesium.HeightReference.CLAMP_TO_GROUND,
+          // 澶у皬鏄惁浠ョ背涓哄崟浣�
+          sizeInMeters: false,
+          // 鐩稿浜庡潗鏍囩殑鍨傜洿浣嶇疆
+          verticalOrigin: Cesium.VerticalOrigin.CENTER,
+          // 鐩稿浜庡潗鏍囩殑姘村钩浣嶇疆
+          horizontalOrigin: Cesium.HorizontalOrigin.LEFT,
+          // 搴旂敤浜庡浘鍍忕殑缁熶竴姣斾緥銆傛瘮渚嬪ぇ浜庝細1.0鏀惧ぇ鏍囩锛岃�屾瘮渚嬪皬浜庝細1.0缂╁皬鏍囩銆�
+          scale: 1.0,
+          // 鏄惁鏄剧ず
+          show: true,
+        },
+      });
+      point.billboard.disableDepthTestDistance = Number.POSITIVE_INFINITY;
+      this.$store.state.pipelineEntity.push(point);
+      sgworld.Navigate.flyToObj(point);
     },
     setShowImageLine(res) {
       var obj = [];
@@ -424,7 +506,7 @@
         .then((_) => {
           this.closeDialog();
         })
-        .catch((_) => {});
+        .catch((_) => { });
     },
     closeDialog() {
       this.dialogVisible = false;
diff --git a/src/views/Tools/queryinfo.vue b/src/views/Tools/queryinfo.vue
index b283a42..1af86b6 100644
--- a/src/views/Tools/queryinfo.vue
+++ b/src/views/Tools/queryinfo.vue
@@ -65,13 +65,18 @@
         return item.id === id;
       });
       let data = this.PopupData.splice(index, 1)[0];
-      // data.close && data.close();
-      if(this.$store.state.primitLayer != null){
-sgworld.Viewer.entities.remove(this.$store.state.primitLayer);
-      sgworld.Creator.DeleteObject(this.$store.state.primitLayer);
-      this.$store.state.primitLayer = null
+      if (this.$store.state.pipelineEntity.length != 0) {
+        for (var i in this.$store.state.pipelineEntity) {
+          sgworld.Viewer.entities.remove(this.$store.state.pipelineEntity[i]);
+        }
+
       }
-      
+      if (this.$store.state.primitLayer != null) {
+        sgworld.Viewer.entities.remove(this.$store.state.primitLayer);
+        sgworld.Creator.DeleteObject(this.$store.state.primitLayer);
+        this.$store.state.primitLayer = null
+      }
+
     },
     // 鎵撳紑寮圭獥
     open(title, value, style = {}) {

--
Gitblit v1.9.3