fix(GRO-2089): correct Authentik customer credential source in UAT_PLAYBOOK §5.25 #42

Merged
Flea Flicker merged 18 commits from flea/gro-2089-fix-authentik-credential-source into dev 2026-06-02 14:48:03 +00:00
2 changed files with 5 additions and 2 deletions
Showing only changes of commit 0e5e9d1f16 - Show all commits
+3 -2
View File
@@ -386,9 +386,10 @@ export function App() {
return <Navigate to="/setup" replace />; return <Navigate to="/setup" replace />;
} }
// Redirect authenticated users to /admin (but preserve impersonation flow via ?sessionId=) // Redirect staff to /admin; allow customers to access portal (preserve impersonation via ?sessionId=)
const searchParams = new URLSearchParams(location.search); const searchParams = new URLSearchParams(location.search);
if (!authDisabled && session && !location.pathname.startsWith("/admin") && !searchParams.has("sessionId")) { const isStaff = session?.user && (session.user as any).role === "staff";
if (!authDisabled && session && !location.pathname.startsWith("/admin") && !searchParams.has("sessionId") && isStaff) {
return <Navigate to="/admin" replace />; return <Navigate to="/admin" replace />;
} }
+2
View File
@@ -39,6 +39,8 @@ export default defineConfig({
], ],
}, },
workbox: { workbox: {
skipWaiting: true,
clientsClaim: true,
globPatterns: ["**/*.{js,css,html,ico,png,svg,woff2}"], globPatterns: ["**/*.{js,css,html,ico,png,svg,woff2}"],
navigateFallbackDenylist: [ navigateFallbackDenylist: [
/^\/api\/auth\//, /^\/api\/auth\//,