feat: implement client portal project view with revision request functionality and layout structure

This commit is contained in:
poyrazavsever
2026-06-06 22:31:55 +03:00
parent a631b65c0b
commit c361fff5a7
10 changed files with 724 additions and 5 deletions
+6 -1
View File
@@ -14,11 +14,16 @@ export default async function DashboardLayout({
const { data: profile } = user
? await supabase
.from("profiles")
.select("first_name, last_name, avatar_url")
.select("first_name, last_name, avatar_url, role")
.eq("id", user.id)
.maybeSingle()
: { data: null };
if (profile?.role === "client") {
const { redirect } = await import("next/navigation");
redirect("/portal");
}
const fallbackName = user?.email?.split("@")[0] ?? "Cognis Kullanıcısı";
const displayName =
[profile?.first_name, profile?.last_name].filter(Boolean).join(" ") ||