From 13fdb067fc3d752e8bd278de539fb2de40fe8397 Mon Sep 17 00:00:00 2001
From: lixuliang <lixuliang_hd@126.com>
Date: 星期五, 10 十一月 2023 18:20:33 +0800
Subject: [PATCH] 土地管理弹窗、工具栏整合、功能点击响应

---
 src/components/menu/bottom-menu.vue |   96 ++++++++++++++++++++++++++++++++++++++++++------
 1 files changed, 84 insertions(+), 12 deletions(-)

diff --git a/src/components/menu/bottom-menu.vue b/src/components/menu/bottom-menu.vue
index c4bbc7b..badb2fb 100644
--- a/src/components/menu/bottom-menu.vue
+++ b/src/components/menu/bottom-menu.vue
@@ -23,7 +23,7 @@
           <img src="@assets/img/new/chengshibujian.png" alt="" />
         </div>
         <div class="textbox">
-          <span> 鍩庡競閮ㄤ欢 </span>
+          <span> 缁煎悎鎵╁睍 </span>
         </div>
         <el-dropdown-menu
           slot="dropdown"
@@ -36,10 +36,12 @@
           <el-dropdown-item command="bzdSystem"
             >鏍囧噯鍦扮洃绠″钩鍙�</el-dropdown-item
           >
-          <el-dropdown-item command="spjkHandle"
+          <el-dropdown-item v-if="isShowSPJK" command="spjkHandle"
             >瑙嗛闆嗘垚涓庡彲瑙嗗寲</el-dropdown-item
           >
-
+          <el-dropdown-item v-else command="closeSpjk"
+            >鍏抽棴瑙嗛鐐逛綅鍒嗗竷</el-dropdown-item
+          >
           <el-dropdown-item v-if="isShowSjxl" command="sjxlHandle"
             >鎵嬫満淇′护鐑姏鍒嗗竷</el-dropdown-item
           >
@@ -65,8 +67,11 @@
         >
           <el-dropdown-item command="fcfhHandle">鍒嗗眰鍒嗘埛</el-dropdown-item>
           <!-- <el-dropdown-item command="sprhHandle">鍦烘櫙瑙嗛铻嶅悎</el-dropdown-item> -->
-          <el-dropdown-item command="jiqirendahui"
+          <el-dropdown-item v-if="isShowSPRH" command="jiqirendahui"
             >鍦烘櫙瑙嗛铻嶅悎</el-dropdown-item
+          >
+          <el-dropdown-item v-else command="jiqirendahui"
+            >鍏抽棴瑙嗛铻嶅悎</el-dropdown-item
           >
         </el-dropdown-menu>
       </el-dropdown>
@@ -341,6 +346,9 @@
   width: 155px;
   border: none;
 }
+.el-dropdown /deep/ .el-dropdown-selfdefine{
+  margin-left: 8px !important;
+}
 .csbj .el-dropdown-menu {
   top: -215px !important;
 }
@@ -428,6 +436,9 @@
   name: "bottom-menu",
   data() {
     return {
+      isShowSPJK: true,
+      isShowSjxl: true,
+      isShowSPRH: true,
       csbjShow: false,
       jxmxShow: false,
       romanOption: [
@@ -609,7 +620,6 @@
       // 閫忔槑搴�
       far: 166,
       videoarrList: [],
-      isShowSjxl: true,
     };
   },
   computed: {
@@ -637,6 +647,9 @@
         case "spjkHandle":
           this.spjkHandle();
           break;
+        case "closeSpjk":
+          this.closeSpjk();
+          break;
         case "stdsjHandle":
           this.stdsjHandle();
           break;
@@ -653,7 +666,7 @@
           this.shoujixinling();
           break;
         case "closeSjxl":
-          this.guanbi();
+          this.closeSjxl();
           break;
         case "csgxHandle":
           this.csgxHandle();
@@ -664,19 +677,40 @@
       }
     },
     tdglHandle() {
+      if (!this.viewer1Show) {
+        const loading = this.$loading({
+          lock: true,
+          text: "鍦熷湴绠$悊鍔熻兘鍔犺浇涓紝璇风◢鍚�",
+          spinner: "el-icon-loading",
+          background: "rgba(0, 0, 0, 0.7)",
+        });
+        setTimeout(() => {
+          loading.close();
+        }, 3500);
+      }
+
       this.setViewer1Show(!this.viewer1Show);
     },
     stdsjHandle() {
+      // window.location.href =
+      //   "http://10.9.2.29:8080/#/login?token=1ed14c5157acb8088efe65bc93a032c3";
       window.open(
         "http://10.9.2.29:8080/#/login?token=1ed14c5157acb8088efe65bc93a032c3"
       );
     },
     bzdSystem() {
-      window.open(
-        "http://192.162.24.2:8076/login"
-      );
+      window.open("http://192.162.24.2:8076/login");
     },
     shoujixinling() {
+      const loading = this.$loading({
+        lock: true,
+        text: "鎵嬫満淇′护鏁版嵁鍔犺浇涓紝璇风◢鍚�",
+        spinner: "el-icon-loading",
+        background: "rgba(0, 0, 0, 0.7)",
+      });
+      setTimeout(() => {
+        loading.close();
+      }, 2000);
       this.isShowSjxl = false;
       let heatMapUrl = URLInCode.heatMapUrl;
       sgworld.Core.getJSON(heatMapUrl, (data) => {
@@ -705,7 +739,7 @@
         });
       });
     },
-    guanbi() {
+    closeSjxl() {
       if (heatMapItem) {
         this.isShowSjxl = true;
         heatMapItem.deleteObject();
@@ -762,6 +796,16 @@
       });
     },
     spjkHandle() {
+      const loading = this.$loading({
+        lock: true,
+        text: "瑙嗛鐐逛綅鏁版嵁鍔犺浇涓紝璇风◢鍚�",
+        spinner: "el-icon-loading",
+        background: "rgba(0, 0, 0, 0.7)",
+      });
+      setTimeout(() => {
+        loading.close();
+      }, 2000);
+      this.isShowSPJK = false;
       if (window.sxtkGeojson) {
         window.sxtkGeojson.deleteObject();
         window.sxtkGeojson = null;
@@ -775,23 +819,51 @@
         // this.spjkLoad();
       }
     },
+    closeSpjk() {
+      this.isShowSPJK = true;
+      if (window.sxtkGeojson) {
+        window.sxtkGeojson.deleteObject();
+        window.sxtkGeojson = null;
+        window.sxthandler.destroy();
+        //鍏抽棴寮圭獥
+        Bus.$emit("closeRightPop", true);
+        layuiLayer.close(SmartEarthPopupData.layerProp);
+        return;
+      } else {
+        Bus.$emit("closeSPJK");
+        // this.spjkLoad();
+      }
+    },
     // 鍒嗗眰鍒嗘埛
     fencengfenhu() {
+      Bus.$emit("switchImage");
+      const loading = this.$loading({
+        lock: true,
+        text: "寤虹瓚瀹炴櫙妯″瀷鍔犺浇涓紝璇风◢鍚�",
+        spinner: "el-icon-loading",
+        background: "rgba(0, 0, 0, 0.7)",
+      });
+      setTimeout(() => {
+        loading.close();
+      }, 2000);
       Bus.$emit("ShowFCFH", true);
     },
     // 鏈哄櫒浜哄ぇ浼氳棰戣瀺鍚�
     async jiqirendahui(item) {
+      Bus.$emit("switch3D");
       var that = this;
+      this.isShowSPRH = false;
       if (that.robotvideoarrList.length > 0) {
         for (var i = 0; i < that.robotvideoarrList.length; i++) {
           that.robotvideoarrList[i].destroy();
           that.robotvideoarrList[i] = undefined;
         }
         that.robotvideoarrList = [];
+        this.isShowSPRH = true;
       } else {
         const loading = this.$loading({
           lock: true,
-          text: "Loading",
+          text: "瑙嗛鏁版嵁鍔犺浇涓紝璇风◢鍚�",
           spinner: "el-icon-loading",
           background: "rgba(0, 0, 0, 0.7)",
         });
@@ -807,7 +879,6 @@
               item[i].cameraIndexCode,
             // url: "http://10.10.4.116:8086/getCamerasInfoHls?cameraIndexCode=49ee9fed701444738112e80a4835122c",
             success: function (result) {
-              loading.close();
               video = sgworld.Creator.Video3D({
                 cameraPosition: position, //鐩告満瀹夎浣嶇疆
                 heading: item[i].heading, //64
@@ -823,6 +894,7 @@
                 useLine: false, //鏄惁璇曠敤杈呭姪绾�
                 success() {
                   sgworld.Navigate.flyToObj(video);
+                  loading.close();
                 },
               });
               that.robotvideoarrList.push(video);

--
Gitblit v1.9.3