From f809fa552d8a8eb95441ccd3d9d1be20f8b5f59b Mon Sep 17 00:00:00 2001 From: Bryan Van Deusen Date: Fri, 17 Apr 2026 23:44:42 -0400 Subject: [PATCH] feat(dashboard): replace recent-failures list with platform health bars + strict failing-source table --- frontend/src/views/Dashboard.vue | 91 +++++++++++++++++++------------- 1 file changed, 54 insertions(+), 37 deletions(-) diff --git a/frontend/src/views/Dashboard.vue b/frontend/src/views/Dashboard.vue index 30c2774..3e8145d 100644 --- a/frontend/src/views/Dashboard.vue +++ b/frontend/src/views/Dashboard.vue @@ -238,27 +238,59 @@ Sources Needing Attention - - {{ sourcesWithErrors.length }} + + {{ totalFailingCount }} - + +
+
Platform Health
+
+ + {{ getPlatformIcon(row.platform) }} + +
{{ row.platform }}
+ +
+ {{ row.failing }}/{{ row.total }} +
+
+
+ No enabled sources +
+
+ + + + + Source - Last Error - Last Check + Consecutive failures + Last check Actions - + {{ getSourceLabel(source) }} - - {{ source.last_error_type || 'failed' }} - + {{ source.error_count }} {{ formatDate(source.last_check) }} @@ -270,11 +302,7 @@ > Retry - + View View in Subscriptions @@ -282,10 +310,8 @@ -
- mdi-check-all -
All sources healthy
-
No failures in the last 7 days
+
+ No sources in failing state
@@ -357,25 +383,6 @@ const failingSources = computed(() => { const totalFailingCount = computed(() => failingSources.value.length) -// Sources with recent failures - derived from recent activity -// Only shows sources where a recent download failed (not cumulative error_count) -const sourcesWithErrors = computed(() => { - const failedDownloads = recentActivity.value.filter(d => d.status === 'failed') - // Group by source_id and keep unique sources with their most recent failure - const sourceMap = new Map() - for (const dl of failedDownloads) { - if (dl.source_id && !sourceMap.has(dl.source_id)) { - sourceMap.set(dl.source_id, { - id: dl.source_id, - subscription_name: dl.subscription_name, - platform: dl.platform, - last_error_type: dl.error_type, - last_check: dl.created_at, - }) - } - } - return Array.from(sourceMap.values()).slice(0, 5) -}) const failedCount = computed(() => stats.value?.active_failed || 0) const activeDownloadsCount = computed(() => @@ -640,4 +647,14 @@ async function retrySource(source) { 0%, 100% { opacity: 1; } 50% { opacity: 0.4; } } + +.platform-label { + min-width: 110px; + text-transform: capitalize; +} + +.count-label { + min-width: 50px; + text-align: right; +}