diff --git a/src/psyc/cockpit/app.py b/src/psyc/cockpit/app.py index 57e0ce4..eef212d 100644 --- a/src/psyc/cockpit/app.py +++ b/src/psyc/cockpit/app.py @@ -50,12 +50,14 @@ def index(request: Request) -> HTMLResponse: got = db.get_case(i.case_id) if not isinstance(got, Err): case_index[i.case_id] = case_visuals.case_glyph_svg(got.value) + buckets = news_line.bucket_items(items) return TEMPLATES.TemplateResponse( request, "home.html", { "kpis": news_line.kpis(), - "buckets": news_line.bucket_items(items), + "buckets": buckets, + "total_items": sum(len(b.items) for b in buckets), "feeds": news_line.feed_health(), "featured": featured, "featured_hero": case_visuals.case_hero_svg(featured) if featured else "", diff --git a/src/psyc/cockpit/templates/home.html b/src/psyc/cockpit/templates/home.html index 3835d41..381c1f4 100644 --- a/src/psyc/cockpit/templates/home.html +++ b/src/psyc/cockpit/templates/home.html @@ -59,7 +59,7 @@

Recent activity

- {{ buckets|sum(attribute='items')|length }} items + {{ total_items }} items

Live feed of what psyc has detected and what it has done about it.