@extends('layouts.main') @section('content')

Audit Logs


@if($audits->isEmpty())
No audit records found.
@else
@foreach($audits as $audit) @endforeach
ID Created At User Type User ID User Name Event Auditable Type Auditable ID Old Values New Values URL IP Address User Agent Tags
{{ $audit->id }} {{ $audit->created_at }} {{ $audit->user_type ?? '-' }} {{ $audit->user_id }} {{ App\User::find($audit->user_id)->name ?? '-' }} {{ ucfirst($audit->event) }} {{ $audit->auditable_type }} {{ $audit->auditable_id }} @if($audit->old_values)
{{ json_encode(json_decode($audit->old_values), JSON_PRETTY_PRINT) }}
@else - @endif
@if($audit->new_values)
{{ json_encode(json_decode($audit->new_values), JSON_PRETTY_PRINT) }}
@else - @endif
{{ $audit->url }} {{ $audit->ip_address }} {{ Str::limit($audit->user_agent, 60) }} {{ $audit->tags ?? '-' }}
{{ $audits->links() }} @endif
@endsection