lookyloo/website/web/templates/stats.html

90 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>
2020-11-27 16:27:29 +01:00
{% for month in year['months'] %}
<h4>{{ month_name(month['month_number']) }}</h4>
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>
<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 15:27:34 +01:00
</tr>
</thead>
<tbody>
<tr>
<td> {{ month['submissions'] }} </td>
<td> {{ month['submissions_with_redirects'] }} </td>
2020-11-25 15:27:34 +01:00
<td> {{ month['redirects'] }} </td>
<td> {{ month['uniq_urls'] }} </td>
<td> {{ month['uniq_domains'] }} </td>
</tr>
</tbody>
</table>
</div>
{% endfor %}
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() }}
2021-12-13 17:02:25 +01:00
<script src='{{ url_for('static', filename='d3.v7.min.js') }}'
integrity="{{get_sri('static', 'd3.v7.min.js')}}"
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 %}