You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
52 lines
1.1 KiB
52 lines
1.1 KiB
generator client { |
|
provider = "prisma-client-js" |
|
} |
|
|
|
datasource db { |
|
provider = "postgresql" |
|
} |
|
|
|
enum Role { |
|
viewer |
|
editor |
|
} |
|
|
|
enum ComponentStatus { |
|
draft |
|
review |
|
approved |
|
} |
|
|
|
model User { |
|
id String @id @default(uuid()) |
|
email String @unique |
|
name String |
|
passwordHash String |
|
role Role @default(viewer) |
|
createdAt DateTime @default(now()) |
|
|
|
components ExperimentalComponent[] |
|
} |
|
|
|
model ExperimentalComponent { |
|
id String @id @default(uuid()) |
|
name String |
|
baseComponent String |
|
attributes Json |
|
status ComponentStatus @default(draft) |
|
author User @relation(fields: [authorId], references: [id]) |
|
authorId String |
|
createdAt DateTime @default(now()) |
|
updatedAt DateTime @updatedAt |
|
} |
|
|
|
model Block { |
|
id String @id @default(uuid()) |
|
path String @unique |
|
name String |
|
version String |
|
isInPreview Boolean @default(false) |
|
changelog Json @default("[]") |
|
updatedAt DateTime @updatedAt |
|
createdAt DateTime @default(now()) |
|
}
|
|
|