@extends('layouts.app-admin') @section('content')
@forelse ($notifications as $row) @php $isUnread = true; if ($row->read_at != null) { $isUnread = false; } @endphp
{{ $row->message }}
{{ \Carbon\Carbon::parse($row->created_at)->locale('id')->diffForHumans() }}
@empty
belum terdapat data
@endforelse {{-- @php $notificationTypes = ['verification', 'system', 'user', 'song']; $notificationStatus = ['unread', 'read']; $timeAgo = [ '5 minutes ago', '30 minutes ago', '1 hour ago', '3 hours ago', 'Yesterday', '2 days ago', ]; @endphp @for ($i = 0; $i < 12; $i++) @php $type = $notificationTypes[array_rand($notificationTypes)]; $status = $notificationStatus[array_rand($notificationStatus)]; $time = $timeAgo[array_rand($timeAgo)]; // Set icon based on type $icon = match ($type) { 'verification' => 'ti-check', 'system' => 'ti-settings', 'user' => 'ti-user', 'song' => 'ti-music', default => 'ti-bell', }; // Set color based on type $color = match ($type) { 'verification' => 'success', 'system' => 'info', 'user' => 'primary', 'song' => 'warning', default => 'secondary', }; // Set message based on type $message = match ($type) { 'verification' => 'New verification request from John Doe', 'system' => 'System update completed successfully', 'user' => 'New user registered: Jane Smith', 'song' => 'New song uploaded: "Amazing Grace"', default => 'You have a new notification', }; // Set detail based on type $detail = match ($type) { 'verification' => 'User has requested Artist verification status', 'system' => 'All system components were updated to the latest version', 'user' => 'A new user has joined the platform', 'song' => 'The Weeknd uploaded a new song to their collection', default => 'Click to view more details about this notification', }; @endphp
{{ $message }}
{{ $detail }}
{{ $time }}
@endfor --}}
{{ $notifications->appends(request()->all())->links() }}
belum terdapat data
{{--
@for ($i = 0; $i < 5; $i++) @php $type = $notificationTypes[array_rand($notificationTypes)]; $time = $timeAgo[array_rand($timeAgo)]; // Set icon based on type $icon = match ($type) { 'verification' => 'ti-check', 'system' => 'ti-settings', 'user' => 'ti-user', 'song' => 'ti-music', default => 'ti-bell', }; // Set color based on type $color = match ($type) { 'verification' => 'success', 'system' => 'info', 'user' => 'primary', 'song' => 'warning', default => 'secondary', }; // Set message based on type $message = match ($type) { 'verification' => 'New verification request from John Doe', 'system' => 'System update completed successfully', 'user' => 'New user registered: Jane Smith', 'song' => 'New song uploaded: "Amazing Grace"', default => 'You have a new notification', }; // Set detail based on type $detail = match ($type) { 'verification' => 'User has requested Artist verification status', 'system' => 'All system components were updated to the latest version', 'user' => 'A new user has joined the platform', 'song' => 'The Weeknd uploaded a new song to their collection', default => 'Click to view more details about this notification', }; @endphp
{{ $message }}
{{ $detail }}
{{ $time }}
@endfor
--}}
{{--
@for ($i = 0; $i < 3; $i++) @php $status = $notificationStatus[array_rand($notificationStatus)]; $time = $timeAgo[array_rand($timeAgo)]; $verificationTypes = ['Artist', 'Composer', 'Cover Creator']; $verType = $verificationTypes[array_rand($verificationTypes)]; $names = [ 'John Doe', 'Jane Smith', 'Mike Johnson', 'Sarah Williams', 'Robert Brown', ]; $name = $names[array_rand($names)]; @endphp
New {{ $verType }} verification request
{{ $name }} has requested {{ $verType }} verification status
{{ $time }}
@endfor
--}} {{--
@for ($i = 0; $i < 4; $i++) @php $status = $notificationStatus[array_rand($notificationStatus)]; $time = $timeAgo[array_rand($timeAgo)]; $systemMessages = [ 'System update completed successfully', 'Database backup completed', 'Security alert: Multiple failed login attempts', 'Storage space is running low (85% used)', 'New version available: v1.2.0', ]; $systemDetails = [ 'All system components were updated to the latest version', 'Automatic database backup has been created and stored', 'Multiple failed login attempts detected from IP 192.168.1.1', 'Please consider cleaning up unused files to free up space', 'A new version is available with bug fixes and new features', ]; $index = array_rand($systemMessages); $message = $systemMessages[$index]; $detail = $systemDetails[$index]; @endphp
{{ $message }}
{{ $detail }}
{{ $time }}
@endfor
--}}
{{-- --}}

Notification Settings

Email Notifications

Push Notifications

@endsection @section('scripts') @endsection