Add proclamations api endpoint
This commit is contained in:
+27
-14
@@ -14,19 +14,20 @@ datasource db {
|
||||
}
|
||||
|
||||
model User {
|
||||
id String @id
|
||||
name String
|
||||
email String
|
||||
emailVerified Boolean @default(false)
|
||||
image String?
|
||||
createdAt DateTime @default(now())
|
||||
updatedAt DateTime @updatedAt
|
||||
roleId Int?
|
||||
role UserRole? @relation(fields: [roleId], references: [id])
|
||||
sessions Session[]
|
||||
accounts Account[]
|
||||
profile Profile?
|
||||
licenseKeys LicenseKey[]
|
||||
id String @id
|
||||
name String
|
||||
email String
|
||||
emailVerified Boolean @default(false)
|
||||
image String?
|
||||
createdAt DateTime @default(now())
|
||||
updatedAt DateTime @updatedAt
|
||||
roleId Int?
|
||||
role UserRole? @relation(fields: [roleId], references: [id])
|
||||
sessions Session[]
|
||||
accounts Account[]
|
||||
profile Profile?
|
||||
licenseKeys LicenseKey[]
|
||||
userProclamations UserProclamations[]
|
||||
|
||||
@@unique([email])
|
||||
@@map("user")
|
||||
@@ -118,6 +119,18 @@ model Proclamation {
|
||||
categoryId Int
|
||||
category ProclamationCategory @relation(fields: [categoryId], references: [id])
|
||||
price Float @default(0.99)
|
||||
userProclamations UserProclamations[]
|
||||
}
|
||||
|
||||
model UserProclamations {
|
||||
userId String
|
||||
user User @relation(fields: [userId], references: [id])
|
||||
proclamationId String
|
||||
proclamation Proclamation @relation(fields: [proclamationId], references: [id])
|
||||
createdAt DateTime @default(now())
|
||||
updatedAt DateTime @updatedAt
|
||||
|
||||
@@id([userId, proclamationId])
|
||||
}
|
||||
|
||||
model SolfeggioFrequency {
|
||||
@@ -140,7 +153,7 @@ model ProclamationCategory {
|
||||
|
||||
model LicenseKey {
|
||||
id String @id @default(uuid())
|
||||
key String
|
||||
key String @unique
|
||||
active Boolean
|
||||
level String
|
||||
userId String
|
||||
|
||||
Reference in New Issue
Block a user