diff --git a/src/app/dashboard/creatividades/page.tsx b/src/app/dashboard/creatividades/page.tsx index 70db5ab..713d05c 100644 --- a/src/app/dashboard/creatividades/page.tsx +++ b/src/app/dashboard/creatividades/page.tsx @@ -2,7 +2,10 @@ import React from 'react'; import { createClient } from '@/lib/supabase/server'; import { redirect } from 'next/navigation'; import { resolveActiveTenant } from '@/lib/tenant-context'; +import { isAgencyRole, userRole } from '@/lib/agency'; import ClientCreativesView from '@/components/ClientCreativesView'; +import AgencyCreativesView from '@/components/AgencyCreativesView'; +import { EmptyState, PageHeader } from '@/components/ui'; export const dynamic = 'force-dynamic'; @@ -15,6 +18,33 @@ export default async function CreatividadesPage() { if (!user) redirect('/login'); const ctx = await resolveActiveTenant(user); + const agency = isAgencyRole(userRole(user)); + + // Agencia en vista global: hay que elegir cliente para pedir relevos / kanban + if (agency && ctx.portfolioWide) { + return ( +