Bewaesserungsanlage/Webserver/Templates/dashboard/dashboard.html

82 lines
2.1 KiB
HTML
Raw Normal View History

2022-08-25 15:37:54 +02:00
<!DOCTYPE html>
<html lang="de">
<head>
<link rel="stylesheet" href="{{ url_for('static', filename='Styles/dashboard.css') }}">
<title>{{ translater.getTranslation("Irrigation") }}{{ translater.getTranslation("system") }}</title>
<style>
@media screen and (min-width: 2051px){
#zones{
grid-template-rows: repeat( {{ (zoneManager.zones|length / 3) + 1 }} , minmax(150px, auto));
}
}
@media screen and (max-width: 2050px) and (min-width: 1351px){
#zones{
grid-template-rows: repeat( {{ (zoneManager.zones|length / 2) + 1 }} , minmax(150px, auto));
}
}
@media screen and (max-width: 1350px){
#zones{
grid-template-rows: repeat( {{ zoneManager.zones|length }} , minmax(150px, auto));
}
}
</style>
<script>
function refreshZone(zone) {
executeAction('get_dashboard_zone_html', zone, '0', 'zone_'+ zone);
}
function refreshPipeline() {
executeAction('get_dashboard_pipeline_html', '0', '0', 'pipeline');
}
function refreshContent() {
refreshPipeline();
{% for zone in zoneManager.zones %}
refreshZone({{zone.number}});
{% endfor %}
}
</script>
</head>
<body>
{% include "header.html" %}
<main>
<h2>{{ translater.getTranslation("Dashboard") }}</h2>
<h3>{{ translater.getTranslation("planed irrigationjobs") }}</h3>
<p>
<button onclick="refreshPipeline()">
refresh
</button>
</p>
<div id="pipeline">
{% include "dashboard/pipeline.html" %}
</div>
<h3>{{ translater.getTranslation("irrigation zones") }}</h3>
<div id="zones">
{% for zone in zoneManager.zones %}
<div id="zone_{{ zone.number }}" class="zone">
{% include "dashboard/zone.html" %}
</div>
{% endfor %}
</div>
</main>
<p><br><br></p>
</body>
</html>