Reorder page to show tables in columns

This commit is contained in:
Edward Betts 2023-12-22 12:18:28 +00:00
parent 223cdc4728
commit a8c4cc51f6

View file

@ -3,7 +3,7 @@
{% block title %}Geocode to Commons: Reports{% endblock %} {% block title %}Geocode to Commons: Reports{% endblock %}
{% block content %} {% block content %}
<div class="m-3"> <div class="container-fluid m-3">
<h1>Geocode reports</h1> <h1>Geocode reports</h1>
<p><a href="{{ url_for("index") }}">Back to index</a></p> <p><a href="{{ url_for("index") }}">Back to index</a></p>
@ -14,6 +14,9 @@
<p>Average response time: {{ average_response_time | int }} milliseconds</p> <p>Average response time: {{ average_response_time | int }} milliseconds</p>
<div class="row">
<div class="col">
<h4>requests per day</h4> <h4>requests per day</h4>
<table class="table table-hover w-auto"> <table class="table table-hover w-auto">
{% for day, day_count in by_day %} {% for day, day_count in by_day %}
@ -24,6 +27,9 @@
{% endfor %} {% endfor %}
</table> </table>
</div>
<div class="col">
<h4>top places</h4> <h4>top places</h4>
<table class="table table-hover w-auto"> <table class="table table-hover w-auto">
{% for place, place_count in top_places %} {% for place, place_count in top_places %}
@ -39,6 +45,8 @@
</tr> </tr>
{% endfor %} {% endfor %}
</table> </table>
</div>
<div class="col">
<h4>missing places</h4> <h4>missing places</h4>
<p>Recent queries that failed to resolve into a place with a category.</p> <p>Recent queries that failed to resolve into a place with a category.</p>
@ -48,13 +56,15 @@
<td class="text-end">{{ log.dt.strftime("%a %d %b %Y at %H:%M:%S") }}</td> <td class="text-end">{{ log.dt.strftime("%a %d %b %Y at %H:%M:%S") }}</td>
<td class="text-end"> <td class="text-end">
<a href="{{ url_for("detail_page", lat=log.lat, lon=log.lon) }}"> <a href="{{ url_for("detail_page", lat=log.lat, lon=log.lon) }}">
{{ "{:.3f},{:.3f}".format(log.lat, log.lon) }} {{ "{:.4f},{:.4f}".format(log.lat, log.lon) }}
</a> </a>
</td> </td>
</tr> </tr>
{% endfor %} {% endfor %}
</table> </table>
</div>
</div>
</div> </div>
{% endblock %} {% endblock %}