From d3a0184556f4a57e8105c7b3c2d6abb4978d7c0f Mon Sep 17 00:00:00 2001
From: xieshen <1397910458@qq.com>
Date: Sun, 22 Nov 2020 16:36:17 +0800
Subject: [PATCH] #add message
---
dashboard/static/dashboard/css/legend.css | 7 +++++++
dashboard/templates/dashboard/index.html | 12 +++++++++---
monitor/static/monitor/js/index-map.js | 10 +++++++++-
3 files changed, 25 insertions(+), 4 deletions(-)
create mode 100644 dashboard/static/dashboard/css/legend.css
diff --git a/dashboard/static/dashboard/css/legend.css b/dashboard/static/dashboard/css/legend.css
new file mode 100644
index 0000000..f4fabde
--- /dev/null
+++ b/dashboard/static/dashboard/css/legend.css
@@ -0,0 +1,7 @@
+.legend {
+ position: absolute;
+ bottom: 10px;
+ left: 10px;
+ opacity: 0.8;
+ z-index: 999;
+}
diff --git a/dashboard/templates/dashboard/index.html b/dashboard/templates/dashboard/index.html
index b5070d3..240acfc 100644
--- a/dashboard/templates/dashboard/index.html
+++ b/dashboard/templates/dashboard/index.html
@@ -5,6 +5,7 @@
+
{% endblock %}
{% block content %}
@@ -202,7 +203,12 @@
-
+
+
+
更新次数
+
+
+
@@ -557,7 +563,7 @@
{#axisLabel: {#}
{# formatter: '{value} ml'#}
{# }#}
- },
+ },
{
type: 'value',
name: '预警账号',
@@ -567,7 +573,7 @@
{#axisLabel: {#}
{# formatter: '{value} °C'#}
{# }#}
- }
+ }
],
series: [
{
diff --git a/monitor/static/monitor/js/index-map.js b/monitor/static/monitor/js/index-map.js
index 824f6f9..b9658bb 100644
--- a/monitor/static/monitor/js/index-map.js
+++ b/monitor/static/monitor/js/index-map.js
@@ -16,9 +16,17 @@ $(function () {
var gansuLayer = L.nonTiledLayer.wms('http://pom.gsdwl.com/geoserver/newmedia/wms', {
layers: 'newmedia:gansu',
transparent: true,
- format: 'image/png'
+ format: 'image/png',
});
map.addLayer(gansuLayer);
+ var gansuLayer_shi = L.nonTiledLayer.wms('http://pom.gsdwl.com/geoserver/newmedia/wms', {
+ layers: 'newmedia:gansu',
+ transparent: true,
+ format: 'image/png',
+ styles:'newmedia:newmedia_gansu_shidaima'
+ });
+ map.addLayer(gansuLayer_shi);
+
// var citypointLayer = L.nonTiledLayer.wms('http://210.77.68.250:8080/geoserver/newmedia/wms', {
// layers: 'newmedia:citypoint',
// transparent: true,