Update proclamation category naming constraints.

This commit is contained in:
NeilClack
2026-03-16 13:39:53 -05:00
parent 52c740b986
commit 4f7622ab42
2 changed files with 14 additions and 1 deletions
@@ -0,0 +1,11 @@
/*
Warnings:
- A unique constraint covering the columns `[parentId,name]` on the table `ProclamationCategory` will be added. If there are existing duplicate values, this will fail.
*/
-- DropIndex
DROP INDEX "ProclamationCategory_name_key";
-- CreateIndex
CREATE UNIQUE INDEX "ProclamationCategory_parentId_name_key" ON "ProclamationCategory"("parentId", "name");
+3 -1
View File
@@ -129,11 +129,13 @@ model SolfeggioFrequency {
model ProclamationCategory {
id Int @id @default(autoincrement())
name String @unique
name String
parentId Int?
parent ProclamationCategory? @relation("CategoryHierarchy", fields: [parentId], references: [id])
children ProclamationCategory[] @relation("CategoryHierarchy")
proclamations Proclamation[]
@@unique([parentId, name])
}
model LicenseKey {