diff --git a/internal/web/ui.go b/internal/web/ui.go index 116e887..54b4dde 100644 --- a/internal/web/ui.go +++ b/internal/web/ui.go @@ -913,6 +913,13 @@ func (u *UI) ensureDevicesLoaded() { } func (u *UI) pageDashboard(w http.ResponseWriter, r *http.Request) { + // First-time setup: if no recognition units exist, guide to wizard. + if u.preview != nil { + if units, err := u.preview.ListRecognitionUnits(); err == nil && len(units) == 0 { + http.Redirect(w, r, "/ui/wizard", http.StatusFound) + return + } + } data := u.deviceOverviewPageData(r, nil, "") if u.tasks != nil { for _, task := range u.tasks.ListTasks() {