@extends('admin.layouts.app') @section('title',get_setting('site_name').' Activity Log') @section('content')

{{__('All Activity Log')}}

{{__('Activity')}}
{{--
--}} {{-- --}} {{--
--}}
@foreach($activities as $key => $user) @if ($user != null) @if($user->previous!=null && $user->present!=null) @php // Decode the JSON strings into associative arrays $oneData = json_decode($user->previous, true); $twoData = json_decode($user->present, true); // Find the differing fields $markedTwoData = []; foreach ($twoData as $key => $value) { if (array_key_exists($key, $oneData) && $oneData[$key] !== $value) { $markedTwoData[$key] = '' . $value . ''; } else { $markedTwoData[$key] = $value; } } @endphp @endif @endif @endforeach
{{__('#')}} {{__('Subject')}} {{__('Date & time')}} {{__('Previous')}} {{__('Present')}} {{__('IP')}} {{__('Modify By')}}
{{ ($key+1) + ($activities->currentPage() - 1)*$activities->perPage() }} {{$user->subject}} {{date('F d, Y , h:i:s A',strtotime($user->created_at))}}{{$user->previous}} @if($user->previous!=null && $user->present!=null) @php foreach ($markedTwoData as $key => $value) { echo $key . ': ' . $value . '
'; } @endphp @else {{$user->present}} @endif
{{$user->ip}} {{ \App\Models\User::where('id',$user->user_id)->value('name')}}
{{ $activities->appends(request()->input())->links() }}
@endsection @section('script') @endsection