2020-04-06 17:17:10 +02:00
{% extends 'base.html' %}
{% block head %}
{% endblock %}
{% block header %}
< h1 class = "display-4" > {{ station.name }}< / h1 >
{% endblock %}
{% block content %}
< section >
2020-04-08 17:50:25 +02:00
{% if e == "empty" %}
< div class = "alert alert-danger" role = "alert" >
Ein oder mehrere Eingabefelder sind leer oder haben das falsche Format.
< / div >
2020-04-11 14:27:42 +02:00
{% elif e == "end-before-start" %}
< div class = "alert alert-danger" role = "alert" >
Das Enddatum darf nicht vor dem Startdatum liegen.
< / div >
2020-04-08 17:50:25 +02:00
{% endif %}
2020-04-06 17:17:10 +02:00
< h2 >
Export
< small class = "text-muted" > Zeitraum wählen< / small >
< / h2 >
< form action = "/station/{{ station.dwd_id }}/export/target/" >
< div class = "row" >
< div class = "col-sm-6" >
< div class = "form-group" >
< label for = "datetimepicker-from" > von< / label >
2020-04-11 15:58:29 +02:00
< input type = "date" value = "{{ fr }}" name = "from" class = "form-control" id = "datetimepicker-from" required min = "{{ station.climate_date_range()[" min " ] } } " max = "{{ station.climate_date_range()[" max " ] } } " >
2020-04-06 17:17:10 +02:00
< / div >
< / div >
< div class = "col-sm-6" >
< div class = "form-group" >
< label for = "datetimepicker-to" > bis< / label >
2020-04-11 15:58:29 +02:00
< input type = "date" value = "{{ to }}" name = "to" class = "form-control" id = "datetimepicker-to" required min = "{{ station.climate_date_range()[" min " ] } } " max = "{{ station.climate_date_range()[" max " ] } } " >
2020-04-06 17:17:10 +02:00
< / div >
< / div >
< / div >
2020-04-11 14:27:42 +02:00
< div class = "row" >
< div class = "col-sm-6" >
< div class = "form-group" >
< div class = "custom-control custom-checkbox" >
< input type = "checkbox" name = "workdays-only" value = "true" class = "custom-control-input" id = "workdays-only" >
< label class = "custom-control-label" for = "workdays-only" > Nur Montag bis Freitag< / label >
< / div >
< / div >
< / div >
< / div >
2020-04-06 17:17:10 +02:00
< button type = "submit" class = "btn btn-primary" > Weiter< / button >
< / form >
< section >
{% endblock %}
{% block foot %}
2020-04-11 14:27:42 +02:00
< script >
$("#datetimepicker-from").change(() => {
$("#datetimepicker-to").attr('min', $("#datetimepicker-from").val());
});
$("#datetimepicker-to").change(() => {
$("#datetimepicker-from").attr('max', $("#datetimepicker-to").val());
});
< / script >
2020-04-06 17:17:10 +02:00
{% endblock %}