@extends('layouts.app') @section('title', 'Accueil') @section('content')

Tableau de bord

Structures ayant dépassé leur délai d’évaluation ( {{$nombreStructuresEnRetard}})
@foreach ($structuresEnRetard as $structure) @foreach ($structure->activites as $activite) @foreach ($activite->evaluations as $evaluation) @endforeach @endforeach @endforeach
Structure Activité Date limite (date_reference) Date réelle (date_evaluation) Retard (jours)
{{ $structure->nom }} {{ $activite->nom ?? $activite->code }} {{ \Carbon\Carbon::parse($evaluation->date_reference)->toDateString() }} @if ($evaluation->date_evaluation) {{ \Carbon\Carbon::parse($evaluation->date_evaluation)->toDateString() }} @else Non évalué @endif @php $ref = \Carbon\Carbon::parse($evaluation->date_reference); $eval = $evaluation->date_evaluation ? \Carbon\Carbon::parse($evaluation->date_evaluation) : \Carbon\Carbon::today(); $jours = $eval->diffInDays($ref, false); @endphp {{ $jours }} j
Top 10 des meilleurs taux d’exécution
@foreach($topStructures as $evaluation) @endforeach
Structure Activité Taux Prévision (%) Taux Réalisation (%) Écart (%)
{{ $evaluation->structure }} {{ $evaluation->activite }} {{ number_format($evaluation->taux_prevision, 2) }} {{ number_format($evaluation->taux_realisation, 2) }} @if ($evaluation->ecart < 5) {{ number_format($evaluation->ecart, 2) }}% @elseif ($evaluation->ecart < 15) {{ number_format($evaluation->ecart, 2) }}% @else { {{ number_format($evaluation->ecart, 2) }}% @endif
Top 10 des taux les plus faibles
@foreach($lowStructures as $evaluation) @endforeach
Structure Activité Taux Prévision (%) Taux Réalisation (%) Écart (%)
{{ $evaluation->structure }} {{ $evaluation->activite }} {{ number_format($evaluation->taux_prevision, 2) }} {{ number_format($evaluation->taux_realisation, 2) }} @if ($evaluation->ecart > -5) {{ number_format($evaluation->ecart, 2) }}% @elseif ($evaluation->ecart > -15) {{ number_format($evaluation->ecart, 2) }}% @else {{ number_format($evaluation->ecart, 2) }}% @endif
Taux moyens par programme
@endsection