From 5ebf0d5fe4de1a9429fa85a8bca633f4765e0215 Mon Sep 17 00:00:00 2001 From: kisfenyo Date: Fri, 27 Feb 2026 09:19:29 +0100 Subject: [PATCH] feat: add auto-refresh toggle on customer detail page Replace the hardcoded 60s meta-refresh with a JavaScript-based timer and a toggle switch in the page header. The preference persists across page loads via localStorage (enabled by default). Co-Authored-By: Claude Opus 4.6 --- .../web/templates/customer_unified.html | 76 ++++++++++++++++++- 1 file changed, 74 insertions(+), 2 deletions(-) diff --git a/hub/internal/web/templates/customer_unified.html b/hub/internal/web/templates/customer_unified.html index a4c5632..6caaef6 100644 --- a/hub/internal/web/templates/customer_unified.html +++ b/hub/internal/web/templates/customer_unified.html @@ -5,7 +5,6 @@ {{if .CustomerName}}{{.CustomerName}}{{else}}{{.CustomerID}}{{end}} — Felhom Hub - {{if .HasReports}}{{end}} @@ -24,7 +23,14 @@ {{if .CustomerName}}{{.CustomerName}}{{else}}{{.CustomerID}}{{end}} {{if .HasReports}} -

Last report: {{timeAgo .Customer.ReceivedAt}} · Controller {{.Customer.ControllerVersion}}

+

+ Last report: {{timeAgo .Customer.ReceivedAt}} · Controller {{.Customer.ControllerVersion}} + +

{{else}}

No reports received yet

{{end}} @@ -875,5 +881,71 @@ }); {{end}} + + {{if .HasReports}} + + + {{end}}