diff options
Diffstat (limited to 'internal/handlers')
| -rw-r--r-- | internal/handlers/handlers.go | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/internal/handlers/handlers.go b/internal/handlers/handlers.go index 366402e..5014f39 100644 --- a/internal/handlers/handlers.go +++ b/internal/handlers/handlers.go @@ -1274,6 +1274,19 @@ func (h *Handler) aggregateShoppingLists(ctx context.Context) []models.ShoppingS return stores } +// HandleTabConditions renders the Conditions tab with live feeds +func (h *Handler) HandleTabConditions(w http.ResponseWriter, r *http.Request) { + HTMLResponse(w, h.templates, "conditions-tab", nil) +} + +// HandleConditionsPage renders the standalone Conditions page with live feeds +func (h *Handler) HandleConditionsPage(w http.ResponseWriter, r *http.Request) { + if err := h.templates.ExecuteTemplate(w, "conditions.html", nil); err != nil { + http.Error(w, "Failed to render conditions page", http.StatusInternalServerError) + log.Printf("Error rendering conditions page: %v", err) + } +} + // isActionableList returns true if the list name indicates an actionable list func isActionableList(name string) bool { lower := strings.ToLower(name) |
