{% extends "ui/_layout.html" %} {% block title %}Dashboard - bty-web{% endblock %} {% block subnav %} {% set right_html %}live{% endset %} {% with sections=None, right_html=right_html %} {% include "ui/_subnav.html" %} {% endwith %} {% endblock %} {% block intro %} {% from "ui/_intro_box.html" import render as intro_box %} {% call intro_box() %} Fleet overview. Counters and recent activity update live as machines check in via PXE, operators bind catalog entries to MACs, image uploads complete, and target boxes signal flash-done. Drill into any count to see the underlying rows. {% endcall %} {% endblock %} {% block content %} {# The counter cards subscribe to /events/machines via SSE; the server publishes a fresh ``dashboard-counts`` HTML fragment on every machine mutation and image upload, which htmx-ext-sse swaps in below. ``sse-target`` opts the swap target into the layout-level "flash green when content changes" animation. #}
{% include "ui/_dashboard_counts.html" %}
{# Sanity checklist. One row per essential condition for PXE + flash to actually work; each row carries a clear green-check / red-cross indicator + a deep link into the page where the condition lives (and, on failure, a "fix it" action). Static at render time; reload to refresh. #}
Sanity checklist {% set _ok = sanity | selectattr("ok") | list | length %} {{ _ok }} / {{ sanity | length }} ready
{# Recent activity slice -- reuses the per-subject events card. Static at request time (reload to refresh); the live SSE stream is wired to the counters above, not here. #} {% with events=recent_events, title="Recent activity", link_to_full="/ui/events" %} {% include "ui/_events_card.html" %} {% endwith %} {% endblock %}