From ab8f3297f7c8243d486c9da0900e4f813b2ea2df Mon Sep 17 00:00:00 2001
From: suerprisePlus <15810472099@163.com>
Date: 星期三, 27 十一月 2024 17:16:46 +0800
Subject: [PATCH] 功能更新

---
 src/views/visualization/msgList.vue |   97 +++++++++++++++---------------------------------
 1 files changed, 31 insertions(+), 66 deletions(-)

diff --git a/src/views/visualization/msgList.vue b/src/views/visualization/msgList.vue
index 34b1cb0..348e901 100644
--- a/src/views/visualization/msgList.vue
+++ b/src/views/visualization/msgList.vue
@@ -1,18 +1,15 @@
 <template>
   <div class="msgBox">
-
     <div class="aside-title">
       <div>鏁呴殰淇℃伅</div>
-      <div @click="sendDataToParent()" class="closeMsg">
-        X
-      </div>
+      <div @click="sendDataToParent()" class="closeMsg">X</div>
     </div>
     <div class="menuTable">
       <table>
         <tr>
-          <th style="width: 100px;">璁惧鍚嶇О</th>
+          <th style="width: 80px">璁惧鍚嶇О</th>
           <th>璁惧浣嶇疆</th>
-          <th style="width: 100px;">鎿嶄綔</th>
+          <th style="width: 40px">鎿嶄綔</th>
         </tr>
         <tr v-for="(item, indx) in $store.state.mapLayers.msgList" :key="indx">
           <td>{{ item.msg }}</td>
@@ -24,72 +21,39 @@
         </tr>
       </table>
     </div>
-
   </div>
 </template>
 
 <script>
+
 import mapConfig from '../../assets/js/mapSdk/mapConfig';
+import menuManager from '../../assets/js/mapSdk/menuManager';
 
-
+import msgList from './msgList.js';
 export default {
-  components: {
-
-  },
-  props: {
-
-  },
+  components: {},
+  props: {},
   data() {
     return {
-      label: null,
-    }
+     
+    };
   },
-  watch: {
-
-  },
-  mounted() {
-
-  },
+  watch: {},
+  mounted() { },
   methods: {
     sendDataToParent() {
-      this.removeLabel();
-      console.log(23);
-
-      this.$emit('childData', '瀛愮粍浠舵暟鎹�');
-
+      msgList.removeLabel();
+      this.$emit('childData', 'close');
     },
-    removeLabel() {
-      if (this.label) {
-        this.label.removeFromMap()
-        this.label = null;
-      }
-    },
+    
     handleClick(item) {
-      this.removeLabel();
-      // const point = mapConfig.getWKTParse(item.point)
-      const point = item.point.split(",")
-      this.label = earthCtrl.factory.createLabel({
-        lon: point[0],
-        lat: point[1],
-        alt: 40,
-        text: item.msg,
-        image: config.sdkImg + 'Workers/image/mark.png',
-        // 鏂囨湰鍋忕Щ閲�
-        pixelOffset: new SmartEarth.Cesium.Cartesian2(0, -50),
-        // 鍥剧墖鍋忕Щ閲�
-        iPixelOffset: new SmartEarth.Cesium.Cartesian2(0, -20)
-      });
-      earthCtrl.userScene.flyTo(this.label)
+      this.$store.state.mapLayers.msgInfoData = {...item};
+      this.$emit('childData', 'showMsgInfoFlag');
+      msgList.removeLabel();
+      msgList.setInit(item)
     },
-    handleClick2(item) {
-
-    },
-    setMsgClose() {
-
-    }
-
-  }
-}
+  },
+};
 </script>
 
 <style lang="scss" scoped>
@@ -111,7 +75,7 @@
     color: #fff;
     width: 100%;
     height: 45px;
-    line-height: 45px;
+    line-height: 35px;
     background-size: 100% 100%;
     background-repeat: no-repeat;
     display: flex;
@@ -122,9 +86,8 @@
     }
 
     .closeMsg :hover {
-      color: #409EFF;
+      color: #409eff;
     }
-
   }
 
   .menuTable {
@@ -140,13 +103,15 @@
 
       th {
         text-align: center;
-
+        word-wrap: break-word;
+        word-break: break-all;
       }
 
       td {
+        word-wrap: break-word;
+        word-break: break-all;
         line-height: 30px;
-        border-bottom: 1px solid #409EFF;
-        ;
+        border-bottom: 1px solid #409eff;
       }
     }
   }
@@ -163,13 +128,13 @@
 ::-webkit-scrollbar-thumb {
   border-radius: 5px;
   -webkit-box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.2);
-  background: #409EFF;
+  background: #409eff;
 }
 
 /*婊氬姩鏉¢噷闈㈣建閬�*/
 ::-webkit-scrollbar-track {
   -webkit-box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.2);
   border-radius: 10px;
-  background: rgba(237, 237, 237, .1);
+  background: rgba(237, 237, 237, 0.1);
 }
-</style>
\ No newline at end of file
+</style>

--
Gitblit v1.9.3