spiderweb/templates/plots.html
2024-03-24 07:47:27 +01:00

97 lines
3.5 KiB
HTML

{% extends "_base.html" %}
<head>
{% block title %}
<title>Some charts end stats from the dx clustes node</title>
{% endblock %}
{% block head %}
{{ super() }}
{% endblock %}
</head>
{% block titles %}
<h1 class="display-4 text-white">PLOTS & STATS</h1>
<p class="lead text-light">Some statistics about this node</p>
{% endblock %}
{% block filters %}
{% endblock %}
{% block contents %}
<div id="dashboard" class="d-flex flex-wrap justify-content-around">
<div class="shadow-lg mb-5 rounded spider_chart" id="form-band_activity">
<div class="d-flex flex-column">
<form method="POST" id="form-continents" enctype="application/x-www-form-urlencoded">
<input type="hidden" name="csrf_token" value="{{ csrf_token() }}" />
<div class="container">
Your continent is:
<select class="form-select flex-shrink" aria-label="continent" id="continentInput">
{% for dict_item in continents['continents']%}
<option value="{{dict_item['id']}}">{{dict_item["description"]}}</option>
{% endfor %}
</select>
</div>
</form>
<div id="chart-band_activity"></div>
</div>
<small><sup id="txt_continent"></sup></small>
</div>
<div class="shadow-lg mb-5 bg-body rounded spider_chart" id="chart-world_dx_spots_live"></div>
<div class="shadow-lg mb-5 bg-body rounded spider_chart" id="chart-hour_band"></div>
<a class="shadow-lg mb-5 bg-body rounded" href="https://sidc.be/silso/" target="_blank" rel="noopener noreferrer">
<img src="https://sidc.be/silso/IMAGES/GRAPHICS/prediSC.png" id="silo-propagation-img"
alt="propagation trend">
</a>
<div class="shadow-lg mb-5 bg-body rounded spider_chart" id="chart-dx_spots_x_month"></div>
<div class="shadow-lg mb-5 bg-body rounded spider_chart" id="chart-dx_spots_trend"></div>
<div class="container-fluid">
<div class="shadow-lg mb-5 bg-body rounded">
<strong>{{ mycallsign }} telnet nodes & users online. </strong>
<br>
Nodes: <strong>{{ who|selectattr('type', 'equalto', 'NODE DXSP')|map(attribute='type')|map('upper')|list|length }}</strong>
<br>
Users: <strong> {{ who|selectattr('type', 'equalto', 'USER EXT')|map(attribute='type')|map('upper')|list|length }}</strong>
<hr>
<table class="table table-striped table-borderless table-sm text-responsive table-hover">
<thead id="telnet-thead">
<tr>
<th scope="col">Callsign</th>
<th scope="col">Type</th>
<th scope="col">Started</th>
<th scope="col" class="d-none d-lg-table-cell d-xl-table-cell">Name</th>
<th scope="col">Avg RTT</th>
</tr>
</thead>
<tbody>
{% for dict_item in who %}
<tr>
<td>{{dict_item["callsign"]}}</td>
<td>{{dict_item["type"]}}</td>
<td>{{dict_item["started"]}}</td>
<td class="d-none d-lg-table-cell d-xl-table-cell">{{dict_item["name"]}}</td>
<td>{{dict_item["average_rtt"]}}</td>
</tr>
{% endfor %}
</tbody>
</table>
</div>
</div>
</div>
{% endblock contents %}
{% block app_data %}
{{ super() }}
var continents_cq={{continents["continents"]|tojson|safe}};
var band_frequencies={{bands["bands"]|tojson|safe}};
{% endblock app_data %}
{% block app_scripts %}
{{ super() }}
<script defer src="https://cdnjs.cloudflare.com/ajax/libs/echarts/5.5.0/echarts.min.js"
integrity="sha512-k37wQcV4v2h6jgYf5IUz1MoSKPpDs630XGSmCaCCOXxy2awgAWKHGZWr9nMyGgk3IOxA1NxdkN8r1JHgkUtMoQ=="
crossorigin="anonymous" referrerpolicy="no-referrer"></script>
<script defer src="static/js/rel/plot.min.js"></script>
{% endblock app_scripts %}