import { notFound } from 'next/navigation'; import { prisma } from '@/lib/prisma'; import AdminNav from '@/components/AdminNav'; import { startDesignWithProduct } from './actions'; export default async function StartDesignPage({ params }: { params: { id: string } }) { const request = await prisma.customRequest.findUnique({ where: { id: params.id }, include: { product: true }, }); if (!request) notFound(); const products = await prisma.product.findMany({ where: { showOnPersonalised: true }, orderBy: { name: 'asc' }, }); return (
Select which product to design this photo on
Photo request details
Customer: {request.customerName}
Originally requested for: {request.product.name}