Files
events-hub/backend/prisma/migrations/20261104190000_customer_address/migration.sql
T
joshuaandClaude Opus 5.5 fbbf72dcd8 Hub 2.0 step 5: the church's address
Own domain R0, Cross Code address R10, domain included R25 (custom price
for other endings), once per invoice and never discounted; renewal date
with a reminder 30 days before, once per renewal, and Renewed to move it on.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-04 16:24:10 +02:00

14 lines
513 B
SQL

-- Hub 2.0: the church's address (own domain R0, Cross Code address R10, domain included R25), one per
-- customer. Existing churches use their own domain.
-- CreateEnum
CREATE TYPE "AddressType" AS ENUM ('own_domain', 'crosscode', 'included');
-- AlterTable
ALTER TABLE "Customer" ADD COLUMN "addressCustomCents" INTEGER,
ADD COLUMN "addressType" "AddressType" NOT NULL DEFAULT 'own_domain',
ADD COLUMN "domain" TEXT,
ADD COLUMN "domainRemindedFor" DATE,
ADD COLUMN "domainRenewsOn" DATE;