From 78dcd8ce814c9f2d4984595f51e96168ccc812dd Mon Sep 17 00:00:00 2001
From: wangzhibo <wangzhibo@shsening.com>
Date: 星期日, 26 九月 2021 11:34:17 +0800
Subject: [PATCH] .
---
js/function.js | 33 ++++++++++++++++++++++++++++++++-
1 files changed, 32 insertions(+), 1 deletions(-)
diff --git a/js/function.js b/js/function.js
index 04ca61a..1a72de7 100644
--- a/js/function.js
+++ b/js/function.js
@@ -145,7 +145,38 @@
"<br /><br /><p><a href='#' onclick='javascript:showDetail(1001,\"" + item["SiteName"] + "\")' >璇︾粏淇℃伅</a></p>";
return html;
});
- map.addLayer(guokongLayer);
+ // add 鍥芥帶鐐�
+ $.getJSON("http://58.246.27.194:7012/dataapi/Bdata?bid=get_1001_list_hour&datatime=2021-09-06%2012:00:00&qindex=pm25", (result) => {
+ var pointColorArr = ["#f33349", "#fff000", "#33347f"];
+ for (var i = 0, len = result.data.result.length; i < len; i++) {
+ var item = result.data.result[i];
+ var jd = result.data.result[i].Longitude;
+ var wd = result.data.result[i].Latitude;
+ var clr = pointColorArr[i % pointColorArr.length];
+ var graphic = new mars3d.graphic.DivLightPoint({
+ position: Cesium.Cartesian3.fromDegrees(jd, wd),
+ style: {
+ color: clr,
+ heightReference: Cesium.HeightReference.CLAMP_TO_GROUND,
+ highlight: {
+ type: "divLightPoint",
+ diffHeight: 600,
+ material: mars3d.MaterialUtil.createMaterialProperty(mars3d.MaterialType.CircleWave, {
+ color: "#ffff00",
+ count: 3,
+ speed: 20,
+ }),
+ },
+ distanceDisplayCondition: new Cesium.DistanceDisplayCondition(0, 200000), //鎸夎璺濊窛绂绘樉绀�
+ },
+ show: true,
+ attr: item,
+ });
+ guokongLayer.addGraphic(graphic);
+ }
+ });
+
+
}
function addWindLayer(item) {
--
Gitblit v1.9.1