A9: operations console, three pause commands, admin and player reports (WEB-30..32, WEB-40..44, WEB-55, AUD-48)
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
3d1e820564
commit
eab141f467
24 files changed
+928
-11
No files matched your search
@@ -0,0 +1,27 @@
|
||||
{% extends "web/base.html" %}
|
||||
{% block title %}{{ title }} · PLM Lottery{% endblock %}
|
||||
{% block content %}
|
||||
<h1>{{ title }}</h1>
|
||||
<section class="card narrow">
|
||||
<h2>Cosa continua</h2>
|
||||
<ul>{% for line in cmd.continues %}<li>{{ line }}</li>{% endfor %}</ul>
|
||||
{% if not enable %}
|
||||
<h2>Verifiche prima della ripresa</h2>
|
||||
<ul>{% for line in cmd.before_resume %}<li>{{ line }}</li>{% endfor %}</ul>
|
||||
<p class="hint">
|
||||
Stato ora: worker {% if worker_alive %}attivo{% else %}<strong>fermo</strong>{% endif %},
|
||||
operazioni in ritardo: {{ late_total }}.
|
||||
</p>
|
||||
{% endif %}
|
||||
<form method="post" novalidate>
|
||||
{% csrf_token %}
|
||||
<input type="hidden" name="enable" value="{% if enable %}1{% else %}0{% endif %}">
|
||||
{% if error %}<p class="message error" role="alert">{{ error }}</p>{% endif %}
|
||||
<label for="reason">Motivo (resta nell'audit)</label>
|
||||
<textarea id="reason" name="reason" rows="3" maxlength="500" required>{{ reason_text }}</textarea>
|
||||
<p><label><input type="checkbox" name="confirm" value="1"> Ho letto cosa comporta e confermo.</label></p>
|
||||
<button class="button" type="submit">{{ title }}</button>
|
||||
<a class="button secondary" href="{% url 'ops:dashboard' %}">Annulla</a>
|
||||
</form>
|
||||
</section>
|
||||
{% endblock %}
|
||||
@@ -0,0 +1,56 @@
|
||||
{% extends "web/base.html" %}
|
||||
{% block title %}Console operativa · PLM Lottery{% endblock %}
|
||||
{% block content %}
|
||||
<h1>Console operativa</h1>
|
||||
|
||||
<section class="card" aria-labelledby="stato">
|
||||
<h2 id="stato">Stato</h2>
|
||||
<dl class="facts">
|
||||
<dt>Round in corso</dt>
|
||||
<dd>{% if round %}n. {{ round.pk }} · {{ round.get_status_display }}{% else %}nessuno{% endif %}</dd>
|
||||
<dt>Prossima scadenza</dt>
|
||||
<dd>{% if round and round.status == "open" %}{{ deadline|date:"H:i:s" }} UTC{% else %}—{% endif %}</dd>
|
||||
<dt>Worker</dt>
|
||||
<dd>
|
||||
{% if worker_alive %}attivo · ultimo battito {{ worker_seen_at|time:"H:i:s" }} UTC
|
||||
{% elif worker_seen_at %}<strong>fermo</strong> · ultimo battito {{ worker_seen_at|date:"j F H:i:s" }} UTC
|
||||
{% else %}<strong>mai avviato</strong>{% endif %}
|
||||
</dd>
|
||||
<dt>Catena</dt>
|
||||
<dd>{% if backend == "simulated" %}simulata (fase A): nessun nodo Electrum da controllare{% else %}Electrum: controllo non ancora disponibile{% endif %}</dd>
|
||||
<dt>Ultima riconciliazione</dt>
|
||||
<dd>non ancora disponibile (arriva con la fase B)</dd>
|
||||
<dt>Operazioni in ritardo</dt>
|
||||
<dd>
|
||||
{% if late_total %}
|
||||
<strong>{{ late_total }}</strong>:
|
||||
{{ late.pending_bets }} puntate in attesa, {{ late.pending_movements }} movimenti in attesa,
|
||||
{{ late.pending_transactions }} transazioni in attesa{% if late.overdue_rounds %}, il round oltre la scadenza{% endif %}
|
||||
{% else %}nessuna{% endif %}
|
||||
</dd>
|
||||
</dl>
|
||||
</section>
|
||||
|
||||
<section class="card" aria-labelledby="comandi">
|
||||
<h2 id="comandi">Pause</h2>
|
||||
<ul class="plain">
|
||||
{% for item in commands %}
|
||||
<li>
|
||||
<strong>{{ item.command.title_on }}</strong> — {% if item.on %}<strong>attiva</strong>{% else %}non attiva{% endif %}
|
||||
{% if item.reason %}<br><span class="hint">Dal {{ item.reason.created_at|date:"j F H:i" }} UTC, {{ item.reason.actor_label }}: {{ item.reason.reason }}</span>{% endif %}
|
||||
<br>
|
||||
{% if item.allowed %}
|
||||
<a class="button small{% if item.on %} secondary{% endif %}" href="{% url 'ops:command' item.command.key %}">{{ item.title }}…</a>
|
||||
{% else %}
|
||||
<span class="hint">Non hai il permesso per questo comando.</span>
|
||||
{% endif %}
|
||||
</li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
</section>
|
||||
|
||||
<section class="card">
|
||||
<h2>Altri strumenti</h2>
|
||||
<p><a href="/admin/">Amministrazione: utenti, segnalazioni, audit</a></p>
|
||||
</section>
|
||||
{% endblock %}
|
||||
Reference in new issue
Block a user