• @if(auth()->user()->role !== App\Models\User::ROLE_ADMIN)
  • {{ $notificationCount }}
    {{ $notificationCount }} Notifications
    @foreach($recentNotifications as $notification) @php $name = $notification->title ?? 'NA'; $parts = explode(' ', $name); $initials = strtoupper(substr($name, 0, 1)); // $initials = strtoupper(substr($parts[0], 0, 1)); // if (count($parts) > 1) { // $initials = strtoupper(substr(end($parts), 0, 1)); // } elseif (strlen($name) > 1) { // $initials = strtoupper(substr($name, 0, 1)); // } $avatarPath = $notification->avatar_path ?? 'img/default_avatar.jpg'; $hasAvatar = !empty($notification->avatar_path) && strpos($avatarPath, 'default_avatar.jpg') === false; @endphp {{-- Image/Initials Placeholder --}}
    @if($hasAvatar) User Avatar @else
    {{ $initials }}
    @endif
    {{-- Text Content Container --}}
    {{ $notification->title }}

    {{ $notification->message }}


    {{ $notification->created_at->diffForHumans() }} {{-- Action buttons/extra details can go here --}} {{-- Example: @if($notification->type === 'appointment') ...buttons... @endif --}}
    {{-- Optional: Move dropdown-divider here for better styling separation --}} @endforeach
    {{-- Footer area remains the same --}} @if(Auth::guard('employee')->check()) See All Notifications @else
    See All Notifications
    Read All
    @endif
  • @endif
  • {{ auth()->user()->name }}

    @if(auth()->user()->role == App\Models\User::ROLE_USER) Profile
    @elseif(Auth::guard('employee')->check()) Profile
    @endif @if(Auth::guard('employee')->check()) {{ __('Logout') }}
    @csrf
    @else {{ __('Logout') }}
    @csrf
    @endif