@extends('backend.layouts.master') @section('title') Audit @endsection @section('css') @endsection @section('body') @endsection @section('content')
Audit
@forelse($audits as $audit) @empty @endforelse
Date Utilisateur Action Modèle Changements
{{ $audit->created_at->format('d/m/Y H:i') }} {{ $audit->user?->firstname }} {{ $audit->user?->name }} {{ ucfirst($audit->action) }} {{ class_basename($audit->model_type) }}
    @if ($audit->model_type == 'App\Models\User' && $audit->model)
  • Utilisateur : {{ $audit->model?->firstname }} {{ $audit->model?->name }}
  • @elseif ($audit->model_type == 'App\Models\Participant' && $audit->model)
  • Participant : {{ $audit->model->user?->firstname }} {{ $audit->model->user?->name }}
  • Événement : {{ $audit->model->event->bo_title }}
  • @elseif ($audit->model_type == 'App\Models\ParticipantWorkshop' && $audit->model)
  • Workshop : {{ $audit->model->workshop->titre ?? 'Workshop inconnu' }}
  • Participant : {{ $audit->model->participant->user->firstname ?? 'Inconnu' }} {{ $audit->model->participant->user->name ?? '' }}
  • Événement : {{ $audit->model->workshop->event->bo_title }}
  • @else {{--
  • Modèle supprimé
  • --}} @endif
@if ($audit->changed_data)
    @foreach (json_decode($audit->changed_data, true) as $field => $value)
  • {{ $field }} : {{ $value }}
  • @endforeach
@else @endif
Aucun log trouvé.
@endsection @section('scripts') @endsection