diff --git a/ipi-survey-platform/src/App.jsx b/ipi-survey-platform/src/App.jsx index 22550aa..3780ffd 100644 --- a/ipi-survey-platform/src/App.jsx +++ b/ipi-survey-platform/src/App.jsx @@ -226,7 +226,7 @@ function App() { } /> - + {/* } /> - + */} + + + + } /> + {/* /> */} + {/* */} +
{beforeHeader} -
diff --git a/ipi-survey-platform/src/pages/Admin/Configuration.jsx b/ipi-survey-platform/src/pages/Admin/Configuration.jsx index a8286e3..2e5e058 100644 --- a/ipi-survey-platform/src/pages/Admin/Configuration.jsx +++ b/ipi-survey-platform/src/pages/Admin/Configuration.jsx @@ -33,20 +33,20 @@ const Configuration = () => { }, [active, navigate]); // Update active tab based on URL - useEffect(() => { - const pathToTab = { - 'quarterly': 'Quarterly Windows', - 'hscodes': 'HS Codes', - 'unitmaster': 'Unit Master', - 'admin-users': 'Admin Users', - 'profile': 'Company Profile' - }; +useEffect(() => { + const pathToTab = { + 'quarterly': 'Quarterly Windows', + 'hscodes': 'HS Codes', + 'unitmaster': 'Unit Master', + 'admin-users': 'Admin Users', + 'profile': 'Company Profile' + }; - const path = location.pathname.split('/').pop(); - if (pathToTab[path] && pathToTab[path] !== active) { - setActive(pathToTab[path]); - } - }, [location.pathname]); + const path = location.pathname.split('/').pop(); + if (pathToTab[path] && pathToTab[path] !== active) { + setActive(pathToTab[path]); + } +}, [location.pathname]); const Breadcrumbs = (
{ + setCurrentPage(page); + // Scroll to top when changing pages + window.scrollTo({ top: 0, behavior: 'smooth' }); + }, pageSize, - totalItems: filteredProfiles.length, + totalItems: filteredProfiles.length, // Use filtered count for pagination pageSizeOptions: [10, 20, 50, 100], + onPageSizeChange: (size) => { + setPageSize(size); + setCurrentPage(1); // Reset to first page when changing page size + } }} /> )}