feat(dashboard): Monitors widget carries uptime; Uptime / SLA retired (#5250)

The Monitors widget opens with a verdict ("1 of 5 monitors down."), then one
row per monitor under a single header: latency and uptime over 24h, 7d and
30d, down monitors first with why and since when, the name linking to the
monitor. Counts follow the type filter. Problems always show; the limit
trims only the healthy rest ("+N more up").

Uptime / SLA (uptime_summary) repeated those numbers per host; migration
0033 moves dashboards onto Monitors. Shared widget styles (.w-verdict,
.w-table, .w-sub, .w-more) carry the widget-shape ruling for the widgets
that follow.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-10-07 13:12:58 -04:00
co-authored by Claude Opus 5.5
parent 4dcf958022
commit b5fcccba5f
10 changed files with 149 additions and 126 deletions
-14
View File
@@ -314,17 +314,3 @@ async def uptime_page():
uptime = await host_svc.compute_uptime(db)
hosts = host_svc.worst_uptime_first(result.scalars().all(), uptime)
return await render_template("hosts/uptime.html", hosts=hosts, uptime=uptime)
@hosts_bp.get("/uptime/widget")
@require_role(UserRole.viewer)
async def uptime_widget():
async with current_app.db_sessionmaker() as db:
result = await db.execute(select(Host).order_by(Host.name))
uptime = await host_svc.compute_uptime(db)
hosts = host_svc.worst_uptime_first(result.scalars().all(), uptime)
return await render_template(
"hosts/uptime_widget.html",
hosts=hosts,
uptime=uptime,
)