From c10c1d1c393c970e81b3f1678711d997c5db7edc Mon Sep 17 00:00:00 2001 From: Felipe Cardoso Date: Thu, 6 Nov 2025 11:11:26 +0100 Subject: [PATCH] Adjust `STATS_FETCH_LIMIT` in admin hooks to align with backend pagination limits --- frontend/src/lib/api/hooks/useAdmin.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/frontend/src/lib/api/hooks/useAdmin.tsx b/frontend/src/lib/api/hooks/useAdmin.tsx index ebe60b7..f9f03c8 100644 --- a/frontend/src/lib/api/hooks/useAdmin.tsx +++ b/frontend/src/lib/api/hooks/useAdmin.tsx @@ -18,7 +18,7 @@ import { useAuth } from '@/lib/auth/AuthContext'; /** * Constants for admin hooks */ -const STATS_FETCH_LIMIT = 10000; // High limit to fetch all records for stats calculation +const STATS_FETCH_LIMIT = 100; // Maximum allowed by backend pagination (use pagination.total for actual count) const STATS_REFETCH_INTERVAL = 30000; // 30 seconds - refetch interval for near real-time stats const DEFAULT_PAGE_LIMIT = 50; // Default number of records per page for paginated lists