From 9356ddd3554e1ddf8847923d0ce2eceeef8411f0 Mon Sep 17 00:00:00 2001
From: shuishen <1109946754@qq.com>
Date: Wed, 23 Jun 2021 11:19:49 +0800
Subject: [PATCH] 图例的修改,目录树调整,图层管理调整,图片更新

---
 widgets/searchL/Widget.js |   12 ++++++++----
 1 files changed, 8 insertions(+), 4 deletions(-)

diff --git a/widgets/searchL/Widget.js b/widgets/searchL/Widget.js
index c1da02e..61b6aa1 100644
--- a/widgets/searchL/Widget.js
+++ b/widgets/searchL/Widget.js
@@ -55,7 +55,7 @@
 
 				$(".searchImg").click(function () {
 					that.getInputData();
-					topic.publish('getLegendsData', that.searchDatas);
+
 					that.addOneEntitys.removeAll();
 					if (typeof that.searchDatas == 'string') {
 						var han = /^[\u4e00-\u9fa5]+$/;
@@ -98,14 +98,13 @@
 				$(".searchColce").click(function () {
 					$('.searchLMain').hide();
 					that.addOneEntitys.removeAll();
-					topic.publish('getLegendsData', '');
+					topic.publish('getLegendsData', "legends", '');
 				})
 
 				$("#local_data").keyup(function (e) {
 					// console.log(e);
 					that.getInputData();
 					if (e.keyCode == 13 && typeof that.searchDatas == 'string') {
-						topic.publish('getLegendsData', that.searchDatas);
 						that.addOneEntitys.removeAll();
 						var han = /^[\u4e00-\u9fa5]+$/;
 						if (han.test(that.searchDatas) || that.searchDatas == '  ') {
@@ -171,10 +170,13 @@
 				if (d == []) {
 					if (n == 0) {
 						this.beginLayUi(d);
+                        topic.publish('getLegendsData', "legends", d, "./images/addL/全景.png", "全景站点");
 					} else if (n == 1) {
 						this.beginLayUi(1, d);
+                        topic.publish('getLegendsData', "legends", d, "./images/addL/监控.png", "监控站点");
 					} else if (n == 2) {
 						this.beginLayUi(1, 1, d);
+                        topic.publish('getLegendsData', "legends", d, "./images/addL/全景.png", "监测站点");
 					}
 				} else {
 					var i = 1;
@@ -186,10 +188,13 @@
 					var data = d;
 					if (n == 0) {
 						this.beginLayUi(data);
+                        topic.publish('getLegendsData', "legends", d, "./images/addL/全景.png", "全景站点");
 					} else if (n == 1) {
 						this.beginLayUi(1, data);
+                        topic.publish('getLegendsData', "legends", d, "./images/addL/监控.png", "监控站点");
 					} else if (n == 2) {
 						this.beginLayUi(1, 1, data);
+                        topic.publish('getLegendsData', "legends", d, "./images/addL/监测.png", "监测站点");
 					}
 				}
 			},
@@ -199,7 +204,6 @@
 				this.map.dataSources.add(dataSourceOne);
 				//面板打开的时候触发
 				var that = this;
-				that.getData(0)
 				layui.use('element', function () {
 					var $ = layui.jquery
 						, element = layui.element;

--
Gitblit v1.9.3