fix: correct status for services with all containers excluded from health checks

When all containers are excluded from health checks, display their actual status
with :excluded suffix instead of misleading hardcoded statuses. This prevents
broken UI state with incorrect action buttons and provides clarity that monitoring
is disabled.

🤖 Generated with Claude Code

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Andras Bacsai
2025-11-19 10:54:51 +01:00
parent f81640e316
commit 498b189286
7 changed files with 317 additions and 31 deletions

View File

@@ -1,13 +1,20 @@
@if (str($complexStatus)->contains('running'))
<x-status.running :status="$complexStatus" />
@elseif(str($complexStatus)->contains('starting'))
<x-status.restarting :status="$complexStatus" />
@elseif(str($complexStatus)->contains('restarting'))
<x-status.restarting :status="$complexStatus" />
@elseif(str($complexStatus)->contains('degraded'))
<x-status.degraded :status="$complexStatus" />
@php
$isExcluded = str($complexStatus)->endsWith(':excluded');
$displayStatus = $isExcluded ? str($complexStatus)->beforeLast(':excluded') : $complexStatus;
@endphp
@if (str($displayStatus)->contains('running'))
<x-status.running :status="$displayStatus" />
@elseif(str($displayStatus)->contains('starting'))
<x-status.restarting :status="$displayStatus" />
@elseif(str($displayStatus)->contains('restarting'))
<x-status.restarting :status="$displayStatus" />
@elseif(str($displayStatus)->contains('degraded'))
<x-status.degraded :status="$displayStatus" />
@else
<x-status.stopped :status="$complexStatus" />
<x-status.stopped :status="$displayStatus" />
@endif
@if ($isExcluded)
<span class="text-xs text-neutral-500 dark:text-neutral-400" title="All containers excluded from health monitoring">(Monitoring Disabled)</span>
@endif
@if (!str($complexStatus)->contains('exited') && $showRefreshButton)
<button wire:loading.remove.delay.shortest wire:target="manualCheckStatus" title="Refresh Status" wire:click='manualCheckStatus'