2017-10-01 09:23:50 +02:00
|
|
|
{% extends "base.html.j2" %}
|
2017-10-02 00:33:03 +02:00
|
|
|
{% block title %}Camétéo - {{ data_type }}{% endblock %}
|
2017-10-01 09:05:50 +02:00
|
|
|
|
|
|
|
{% block styles %}
|
|
|
|
{{super()}}
|
2017-10-01 18:14:12 +02:00
|
|
|
{{ css_resources|safe }}
|
|
|
|
{{ js_resources|safe }}
|
2017-10-01 09:05:50 +02:00
|
|
|
{% endblock %}
|
|
|
|
|
|
|
|
{% block content %}
|
|
|
|
{% from "bootstrap/pagination.html" import render_pagination %}
|
|
|
|
<div class="container">
|
2017-10-01 18:14:12 +02:00
|
|
|
|
2017-10-01 09:05:50 +02:00
|
|
|
{{ plot_div|safe }}
|
2017-10-01 18:14:12 +02:00
|
|
|
|
2017-10-02 00:33:03 +02:00
|
|
|
<div id="json">
|
|
|
|
<a href="/json_type_id={{ data_type }}">Télécharger les données (JSON)</a>
|
|
|
|
</div>
|
|
|
|
|
2017-10-01 09:05:50 +02:00
|
|
|
{{ render_pagination(dat) }}
|
2017-10-01 18:14:12 +02:00
|
|
|
|
2017-10-01 09:05:50 +02:00
|
|
|
<div class="table-responsive">
|
|
|
|
<table class="table table-hover">
|
|
|
|
<thead class="thead-inverse">
|
|
|
|
<tr>
|
|
|
|
<th>Date/Heure</th>
|
|
|
|
<th>Type</th>
|
|
|
|
<th>Valeur</th>
|
|
|
|
<th>Capteur</th>
|
|
|
|
</tr>
|
|
|
|
</thead>
|
|
|
|
<tbody>
|
|
|
|
{% for item in dat.items -%}
|
|
|
|
{% if item.value is number %}
|
|
|
|
<tr>
|
|
|
|
{% else %}
|
|
|
|
<tr class="warning">
|
|
|
|
{% endif %}
|
|
|
|
<td>{{ item.valdate }}</td>
|
|
|
|
<td><a href="/type_id={{ item.type_id }}">{{ item.type_id }}</a></td>
|
|
|
|
<td>{{ item.value }} {{ item.unit }}</td>
|
|
|
|
<td><a href="/sensor_id={{ item.sensor_id }}">{{ item.sensor_id }}</a></td>
|
|
|
|
</tr>
|
2017-10-01 09:23:50 +02:00
|
|
|
{%- endfor %}
|
2017-10-01 09:05:50 +02:00
|
|
|
</tbody>
|
|
|
|
</table>
|
|
|
|
{{ render_pagination(dat) }}
|
|
|
|
</div>
|
|
|
|
</div>
|
2017-10-01 18:14:12 +02:00
|
|
|
|
2017-10-01 09:05:50 +02:00
|
|
|
{{ plot_script|safe }}
|
|
|
|
|
2017-10-01 09:23:50 +02:00
|
|
|
{% endblock %}
|