lookyloo/website/web/templates/stats.html

91 lines
2.5 KiB
HTML
Raw Normal View History

2020-11-25 12:08:07 +01:00
{% extends "main.html" %}
{% block title %}Statistics{% endblock %}
{% block content %}
<div>
2020-11-27 16:27:29 +01:00
{% for week in stats['weeks'] %}
<h2> Week: {{ week['week_number'] }}</h2>
2020-11-25 15:27:34 +01:00
<div class="table-responsive">
2020-11-25 12:08:07 +01:00
<table id="table" class="table" style="width:96%">
2020-11-25 15:27:34 +01:00
<thead>
2020-11-25 12:08:07 +01:00
<tr>
<th>Submissions</th>
<th>Submissions with redirects</th>
<th>Redirects</th>
2020-11-26 22:26:22 +01:00
<th>Unique urls (including redirects)</th>
<th>Unique domains (including redirects)</th>
2020-11-25 12:08:07 +01:00
</tr>
2020-11-25 15:27:34 +01:00
</thead>
<tbody>
2020-11-25 12:08:07 +01:00
<tr>
<td> {{ week['submissions'] }} </td>
<td> {{ week['submissions_with_redirects'] }} </td>
2020-11-27 16:27:29 +01:00
<td> {{ week['redirects'] }} </td>
<td> {{ week['uniq_urls'] }} </td>
<td> {{ week['uniq_domains'] }} </td>
2020-11-25 12:08:07 +01:00
</tr>
2020-11-25 15:27:34 +01:00
</tbody>
</table>
</div>
2020-11-25 12:08:07 +01:00
{% endfor %}
</div>
<div>
2020-11-27 16:27:29 +01:00
{% for year in stats['years'] %}
<h2>Year: {{ year['year'] }}</h2>
2020-11-25 15:27:34 +01:00
<ul>
<li><b>Total submissions</b>: {{ year['yearly_submissions'] }}</li>
2020-11-27 16:27:29 +01:00
<li><b>Total redirects</b>: {{ year['yearly_redirects'] }}</li>
2020-11-25 15:27:34 +01:00
</ul>
2020-11-25 12:08:07 +01:00
<div>
2022-02-28 13:38:45 +01:00
<div class="table-responsive">
<table id="table" class="table" style="width:96%">
<thead>
<tr>
<th>Month</th>
<th>Submissions</th>
<th>Submissions with redirects</th>
<th>Redirects</th>
<th>Unique urls (including redirects)</th>
<th>Unique domains (including redirects)</th>
</tr>
</thead>
<tbody>
2020-11-27 16:27:29 +01:00
{% for month in year['months'] %}
2020-11-25 15:27:34 +01:00
<tr>
2022-02-28 13:38:45 +01:00
<td> {{ month_name(month['month_number']) }} </td>
<td> {{ month['submissions'] }} </td>
<td> {{ month['submissions_with_redirects'] }} </td>
<td> {{ month['redirects'] }} </td>
<td> {{ month['uniq_urls'] }} </td>
<td> {{ month['uniq_domains'] }} </td>
2020-11-25 15:27:34 +01:00
</tr>
{% endfor %}
2022-02-28 13:38:45 +01:00
</tbody>
</table>
</div>
2020-11-25 12:08:07 +01:00
</div>
{% endfor %}
</div>
2020-11-26 22:26:22 +01:00
<div class='graphs'></div>
{% endblock %}
2020-11-25 20:17:36 +01:00
2020-11-26 22:26:22 +01:00
{% block scripts %}
{{ super() }}
<script src='{{ url_for('static', filename='d3.min.js') }}'
integrity="{{get_sri('static', 'd3.min.js')}}"
2021-12-13 17:02:25 +01:00
crossorigin="anonymous"></script>
<script src='{{ url_for('static', filename='stats_graph.js') }}'
integrity="{{get_sri('static', 'stats_graph.js')}}"
crossorigin="anonymous"></script>
2020-11-25 12:08:07 +01:00
{% endblock %}
2020-12-07 13:33:14 +01:00
{% block styles %}
{{ super() }}
2021-06-17 02:36:01 +02:00
<link rel="stylesheet" href="{{ url_for('static', filename='stats.css') }}"
integrity="{{get_sri('static', 'stats.css')}}"
crossorigin="anonymous">
2020-12-07 13:33:14 +01:00
{% endblock %}