Shared layout, tabs, and sidebar timer; user onboarding and registration polish; settings danger zone and data export; chart and tRPC perf fixes; migrations for onboarding and dropped appearance columns. Co-authored-by: Cursor <cursoragent@cursor.com>
12 lines
391 B
SQL
12 lines
391 B
SQL
ALTER TABLE "beenvoice_user" ADD COLUMN IF NOT EXISTS "onboardingCompletedAt" timestamp;
|
|
|
|
-- Users who already have a business are treated as onboarded
|
|
UPDATE "beenvoice_user" u
|
|
SET "onboardingCompletedAt" = COALESCE(u."onboardingCompletedAt", NOW())
|
|
WHERE u."onboardingCompletedAt" IS NULL
|
|
AND EXISTS (
|
|
SELECT 1
|
|
FROM "beenvoice_business" b
|
|
WHERE b."createdById" = u."id"
|
|
);
|