{% extends "base.html" %}
{% block title %}suvi - Manage{% endblock %}

{% block content %}

{% if message is not none %}
<h3 class="mb-2">Message</h3>
<div class="alert alert-info" role="alert">
    {{ message }}
</div>
{%endif %}

{% if infos is not none %}
<h3 class="mb-2">Infos</h3>
<table class="table">
    <thead>
        <tr>
            <th style="width: 200px">Key</th>
            <th>Value</th>
        </tr>
    </thead>
    <tbody>
        {% for key, value in infos.items() %}
        <tr>
            <td>{{ key }}</td>
            <td><code>{{ value }}</code></td>
        </tr>
        {% endfor %}
    </tbody>
</table>
{%endif %}

<h3 class="mb-2 mt-5">Management tasks</h3>
<ul>
    <li><a href="{{url_for('app_clean_task_logs')}}"><img src="/static/img/recycle.png" title="Clear all task logs">Clear all task logs</a></li>
    <li><a href="{{url_for('app_shutdown')}}"><img src="/static/img/shutdown.png" title="Stop all tasks and schedules">Stop all tasks and schedules</a></li>
    <li><a href="{{url_for('telemetry_json')}}"><img src="/static/img/code.png" title="Telemetry data as JSON">Telemetry data</a></li>
</ul>
{% endblock %}