revamp notification system
This commit is contained in:
@@ -111,7 +111,10 @@ class DashboardController extends Controller
|
||||
->where('is_read', 0);
|
||||
|
||||
// Ambil data dan kembalikan sebagai JSON
|
||||
return response()->json($notifications->limit(6)->get());
|
||||
return response()->json([
|
||||
'count' => $notifications->count(),
|
||||
'data' => $notifications->take(7)->get(),
|
||||
]);
|
||||
}
|
||||
|
||||
public function mark_read()
|
||||
|
||||
Reference in New Issue
Block a user