@extends('admin.layout') @section('title', 'Signaleringsplannen') @section('content')
{{-- Stats --}}

{{ __('Total') }}

{{ number_format($stats['total']) }}

{{ __('Setup complete') }}

{{ number_format($stats['setup']) }}

@if($stats['total'] > 0)

{{ round($stats['setup'] / $stats['total'] * 100) }}%

@endif

{{ __('With zones') }}

{{ number_format($stats['with_zones']) }}

@if($stats['total'] > 0)

{{ round($stats['with_zones'] / $stats['total'] * 100) }}%

@endif
{{-- Filters --}}
@if(request()->hasAny(['q','setup','sort','dir'])) {{ __('Reset') }} @endif
{{-- Table --}}
@php $th = fn(string $col, string $label) => '' . '' . $label . (request('sort') === $col ? (request('dir') === 'asc' ? ' ▲' : ' ▼') : '') . ''; @endphp
{!! $th('id', 'ID') !!} {!! $th('zones_count', __('Zones')) !!} {!! $th('created_at', __('Created')) !!} @forelse($plans as $plan) @empty @endforelse
{{ __('User') }} {{ __('Setup') }}{{ __('Thoughts') }} {{ __('Reframes') }} {{ __('Sensory') }}
{{ $plan->id }} @if($plan->user) #{{ $plan->user->id }} {{ $plan->user->name }}

{{ $plan->user->email }}

@else @endif
@if($plan->is_setup) {{ __('Yes') }} @else {{ __('No') }} @endif {{ $plan->zones_count }} {{ $plan->has_thoughts ? '✓' : '—' }} {{ $plan->has_reframes ? '✓' : '—' }} {{ $plan->has_sensory ? '✓' : '—' }} {{ $plan->created_at->format('d M Y') }}
{{ __('No signal plans found.') }}
@if($plans->hasPages())
{{ $plans->links() }}
@endif
@endsection