From 7578c3ff65329b2269f099475eb687e963efac1c Mon Sep 17 00:00:00 2001
From: riku <risaku@163.com>
Date: 星期二, 27 二月 2024 17:13:29 +0800
Subject: [PATCH] 地图3D模型、折线图和表格三者点击联动效果

---
 lib/dialog.js |   27 +++++++++++++++++++++++++--
 1 files changed, 25 insertions(+), 2 deletions(-)

diff --git a/lib/dialog.js b/lib/dialog.js
index c011b95..0166bcd 100644
--- a/lib/dialog.js
+++ b/lib/dialog.js
@@ -1,4 +1,13 @@
 var DialogUtil = {
+  show: true,
+  toggleDataDialog() {
+    this.show = !this.show;
+    if (this.show) {
+      return '鏁版嵁寮规锛氬紑';
+    } else {
+      return '鏁版嵁寮规锛氬叧';
+    }
+  },
   /**
    * 鍒涘缓寮瑰嚭妗�
    * @param {*} factorDatas 鐩戞祴鏁版嵁
@@ -64,7 +73,7 @@
     tag += "<div class='time'>" + '鏃堕棿: ' + time;
 
     // 閬嶅巻绔欑偣鏁版嵁涓殑姣忎竴椤圭洃娴嬪洜瀛愶紝鐢熸垚椤甸潰
-    content += "<table class='text-table'>";
+    content += "<div><table class='text-table'>";
     var _contents = new Map();
     factorList.forEach((f) => {
       // 鍒犻�変笉鏄剧ず鐨勫洜瀛�
@@ -122,7 +131,9 @@
       content += _contents.get(e);
     });
 
-    content += '</table>';
+    // content += 
+
+    content += '</table></div>';
 
     var info = document.createElement('div');
     // info.className = "custom-info input-card content-window-card";
@@ -223,4 +234,16 @@
     info.appendChild(bottom);
     return info;
   },
+
+  openNewWindow(factorDatas, i, map, position, onClose) {
+    if (!this.show) return
+    const window = this.createInfoWindow(factorDatas, i, onClose)
+    window.open(map, position);
+  },
+
+  openNewWindow2(factorData, map, position, onClose) {
+    if (!this.show) return
+    const window = this.createInfoWindow2(factorData, onClose)
+    window.open(map, position);
+  }
 };

--
Gitblit v1.9.3