diff --git a/src/components/cases/convert-to-collections-dialog.tsx b/src/components/cases/convert-to-collections-dialog.tsx index 4ddfdd8..d3df272 100644 --- a/src/components/cases/convert-to-collections-dialog.tsx +++ b/src/components/cases/convert-to-collections-dialog.tsx @@ -87,6 +87,11 @@ export function ConvertToCollectionsDialog({ const [status, setStatus] = useState("none"); const [includeEmpty, setIncludeEmpty] = useState(false); const [emptyName, setEmptyName] = useState(""); + // When true (default), create ONE combined collection for the case using + // the first selected contact as the primary homeowner. When false, fall + // back to one collection per selected contact. + const [combine, setCombine] = useState(true); + const [primaryId, setPrimaryId] = useState(null); useEffect(() => { if (!open) return; @@ -95,6 +100,8 @@ export function ConvertToCollectionsDialog({ setStatus("none"); setIncludeEmpty(false); setEmptyName(""); + setCombine(true); + setPrimaryId(null); (async () => { setLoading(true); const { data: ccs, error } = await supabase