@extends('layouts.app') @section('title', 'Health Check') @section('content')
Device Health Report
{{ $online }} Online {{ $offline }} Offline
Refresh All
@foreach($results as $r) @php $device = $r['device']; @endphp
{{ $device->name }}
{{ $device->ip_address }}:{{ $device->port }} @if($device->location)
{{ $device->location }}
@endif
@if($r['online']) ONLINE @else OFFLINE @endif
Latency
{{ $r['latency_ms'] !== null ? $r['latency_ms'].' ms' : '—' }}
Last Mode
@if($device->last_sent_mode) {{ strtoupper($device->last_sent_mode) }} @else @endif
{{ $r['message'] }}
@if($device->last_seen_at)
Last seen: {{ $device->last_seen_at->diffForHumans() }}
@endif
Send
@endforeach
{{-- Summary table --}}
Summary
@foreach($results as $r) @php $d = $r['device']; @endphp @endforeach
DeviceIPStatusLatencyMessageLast SeenLast Sent
{{ $d->name }} {{ $d->ip_address }} @if($r['online']) Online @else Offline @endif {{ $r['latency_ms'] !== null ? $r['latency_ms'].' ms' : '—' }} {{ $r['message'] }} {{ $d->last_seen_at?->diffForHumans() ?? '—' }} @if($d->last_sent_mode) {{ strtoupper($d->last_sent_mode) }} {{ $d->last_sent_at?->format('d/m H:i') }} @else @endif
@endsection @push('scripts') @endpush