integrate users

This commit is contained in:
rgrgogu
2026-05-06 14:14:54 +08:00
parent 569442bf33
commit f165e8b3bb
35 changed files with 2516 additions and 24 deletions
+10 -4
View File
@@ -22,6 +22,8 @@ import AdminSideTabs from "../components/AdminSideTabs"
import UserMenu from "@/components/generic/UserMenu"
import { ROLE_CONFIG } from "@/data/profile.data"
import { AdminProvider } from "@/contexts/provider/AdminProvider" // ← add
const AdminLayout = () => {
const { user, logout } = useAuth();
const navigate = useNavigate();
@@ -81,10 +83,14 @@ const AdminLayout = () => {
<AdminSideTabs />
</div>
</div>
<div id="main-body">
<Outlet />
<Toaster position="bottom-right" richColors />
</div>
{/* ─── All admin contexts live here, scoped to admin routes only ── */}
<AdminProvider>
<div id="main-body">
<Outlet />
<Toaster position="bottom-right" richColors />
</div>
</AdminProvider>
</TooltipProvider>
</section>
)