{{ session('success') }}
@endif
@if (isset($errors) && $errors->any())
-
@foreach ($errors->all() as $error)
- {{ $error }} @endforeach
Alert #{{ $log->alert_no ?? ('EMG-' . str_pad($log->id, 5, '0', STR_PAD_LEFT)) }}
Triggered on: {{ $log->created_at ? $log->created_at->format('d M Y, h:i A') : '-' }}
@if($log->status === 'active')
ACTIVE EMERGENCY
@else
RESOLVED
@endif
Partner / User:
@if($log->user)
@php
$panicUser = $log->user;
$panicIsPartner = $panicUser->account_type === 'partner';
$panicUrl = $panicIsPartner && Route::has('admin.partners.show')
? route('admin.partners.show', $panicUser->id)
: (Route::has('users.view') ? route('users.view', $panicUser->id) : null);
@endphp
@if($panicUrl)
{{ $panicUser->name ?: ('User #' . $panicUser->id) }}
@else
{{ $panicUser->name ?: ('User #' . $panicUser->id) }}
@endif
@else
N/A
@endif
Emergency Reason:
{{ $log->reason ?: 'Emergency help needed immediately' }}
Associated Booking:
@if($log->booking)
#{{ $log->booking->booking_no }}
@else
Standalone (No active booking)
@endif
Live Location:
@if($log->address)
{{ $log->address }}
@endif
@if($log->latitude && $log->longitude)
Open Google Maps
@else
Coordinates not available
@endif
Admin Resolution Remark
Resolved{{ $log->admin_remark ?: 'Marked as resolved without remark.' }}
@if($log->resolved_at)
Resolved at: {{ $log->resolved_at->format('d M Y, h:i A') }}
@endif
Emergency Contacts Alerted at Incident
{{ count($alertedContacts) }} Contact(s)
@if(count($alertedContacts) > 0)
@else
@endif
| # | Contact Name | Relationship | Phone Number | Alert Status | Quick Actions |
|---|---|---|---|---|---|
| {{ $index + 1 }} |
{{ $name }}
|
{{ $relation }} | {{ $phone }} | Alert Sent |
No emergency contacts were attached to this panic alert at the time it was triggered.