aboutsummaryrefslogtreecommitdiffstats
path: root/snag/templates/show_entries.html
diff options
context:
space:
mode:
Diffstat (limited to 'snag/templates/show_entries.html')
-rw-r--r--snag/templates/show_entries.html44
1 files changed, 44 insertions, 0 deletions
diff --git a/snag/templates/show_entries.html b/snag/templates/show_entries.html
new file mode 100644
index 0000000..86451df
--- /dev/null
+++ b/snag/templates/show_entries.html
@@ -0,0 +1,44 @@
+{% extends "layout.html" %}
+{% block body %}
+ <aside>
+ <b>{% if devId == 1 %}Bedroom
+ {% else %}Mainfloor
+ {% endif %}Currently:</b>
+ <ul class=current>
+ <li>{{ current.temperature }}&#176;F</li>
+ <li>{{ current.humidity }}% humidity</li>
+ </ul>
+ </aside>
+ <figure>
+ <embed type="image/png" src="/htgraph.png?deviceId={{ devId }}" />
+ </figure>
+ <figure>
+ <embed type="image/png" src="/pgraph.png?deviceId={{ devId }}" />
+ </figure>
+ {% if devId == 2 %}
+ <figure>
+ <embed type="image/png" src="/bgraph.png?deviceId={{ devId }}" />
+ </figure>
+ {% endif %}
+
+ <hr>
+ <h2>Readings from the past 24 hours</h2>
+ <p>
+ <table class=log>
+ <tr>
+ <th>Timestamp</th>
+ <th>Temperature (C)</th>
+ <th>Humidity (%)</th>
+ <th>Pressure (hPa)</th>
+ </tr>
+ {% for entry in log %}
+ <tr>
+ <td>{{ entry.date }}</td>
+ <td>{{ entry.temperature }}</td>
+ <td>{{ entry.humidity }}</td>
+ <td>{{ entry.pressure }}</td>
+ </tr>
+ {% endfor %}
+ </table>
+ </p>
+{% endblock %}