fix: allow groomer/receptionist roles to read staff records #151

Closed
groombook-engineer[bot] wants to merge 24 commits from fix/gro-162-groomer-staff-rbac into main
Showing only changes of commit af7a670813 - Show all commits
+6 -6
View File
@@ -143,11 +143,6 @@ export function App() {
.catch(() => setAuthDisabled(false));
}, []);
// Show login selector page (only in development)
if (import.meta.env.DEV && location.pathname === "/login") {
return <DevLoginSelector />;
}
// Public booking redirect pages — no auth or portal chrome needed
if (location.pathname === "/booking/confirmed") {
return <BookingConfirmedPage />;
@@ -162,8 +157,13 @@ export function App() {
// Still loading auth state
if (authDisabled === null || sessionLoading) return null;
// Dev mode: show login selector
if (authDisabled && location.pathname === "/login") {
return <DevLoginSelector />;
}
// Dev mode: use dev login selector
if (authDisabled && !getDevUser() && location.pathname !== "/login") {
if (authDisabled && !getDevUser()) {
return <Navigate to="/login" replace />;
}