A ticket records a known problem: title, area, hosts, subject, description, links to alert rules and anomalies, and a log of comments, edits, resolving and reopening. Opening, resolving (with the resolution as the note) and reopening go on the timeline; every step is audited, and the audit rows stay off the timeline. An alert or anomaly an open ticket covers (by link, by subject, or a host-wide ticket on the host itself) shows a Known issue badge, and offers "Open a ticket" prefilled from its rule or anomaly when none does. Hosts, monitors and containers get a Known issues card. MCP: list_tickets, get_ticket (viewer); open_ticket, update_ticket, comment_ticket, resolve_ticket, reopen_ticket (operator). list_alerts and list_anomalies carry known_issue; get_overview, get_host, get_monitor and get_container carry open_tickets. Also update_change and delete_change for changes recorded by hand (author or admin). Tickets are left out of backups, like the timeline (2026-10-15 ruling). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
23 lines
1.1 KiB
HTML
23 lines
1.1 KiB
HTML
{# tickets/_card.html — the open tickets a host's, monitor's or container's
|
|
page lists, loaded into it; nothing but the button when there are none. #}
|
|
{% set can_edit = session.user_role in ('operator', 'admin') %}
|
|
{% set query = ({"host": host} if host else {"subject": subject}) %}
|
|
{% if tickets or can_edit %}
|
|
<section class="card" aria-labelledby="known-issues">
|
|
<div style="display:flex;align-items:baseline;justify-content:space-between;gap:1rem;">
|
|
<h3 id="known-issues" class="section-title">{% if tickets %}Known issues ({{ tickets|length }} open){% else %}Known issues{% endif %}</h3>
|
|
{% if can_edit %}<a class="field-hint" href="/tickets/new?{{ dict(query, back=back)|urlencode }}">Open a ticket</a>{% endif %}
|
|
</div>
|
|
{% if tickets %}
|
|
<ul class="check-list">
|
|
{% for t in tickets %}
|
|
<li><a href="/tickets/{{ t.id }}"><span class="tone-dim">#{{ t.id }}</span> {{ t.title }}</a>
|
|
<span class="field-hint">· {{ t.opened_by }}, {{ t.opened_at|when }}</span></li>
|
|
{% endfor %}
|
|
</ul>
|
|
{% else %}
|
|
<p class="field-hint" style="margin:0;">No open tickets.</p>
|
|
{% endif %}
|
|
</section>
|
|
{% endif %}
|