Rollen Freigaben Push und Beleg Upload ueberarbeiten
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
generator client {
|
||||
provider = "prisma-client-js"
|
||||
output = "../node_modules/.prisma/client"
|
||||
}
|
||||
|
||||
datasource db {
|
||||
@@ -8,7 +9,8 @@ datasource db {
|
||||
}
|
||||
|
||||
enum Role {
|
||||
ADMIN
|
||||
BOARD
|
||||
ORGA
|
||||
FINANCE
|
||||
MEMBER
|
||||
}
|
||||
@@ -43,12 +45,27 @@ model User {
|
||||
createdExpenses Expense[] @relation("ExpenseCreator")
|
||||
approvals Approval[]
|
||||
auditLogs AuditLog[]
|
||||
pushSubscriptions PushSubscription[]
|
||||
createdAt DateTime @default(now()) @map("created_at")
|
||||
updatedAt DateTime @updatedAt @map("updated_at")
|
||||
|
||||
@@map("users")
|
||||
}
|
||||
|
||||
model PushSubscription {
|
||||
id String @id @default(cuid())
|
||||
userId String @map("user_id")
|
||||
endpoint String @unique
|
||||
p256dh String
|
||||
auth String
|
||||
user User @relation(fields: [userId], references: [id], onDelete: Cascade)
|
||||
createdAt DateTime @default(now()) @map("created_at")
|
||||
updatedAt DateTime @updatedAt @map("updated_at")
|
||||
|
||||
@@index([userId])
|
||||
@@map("push_subscriptions")
|
||||
}
|
||||
|
||||
model AccountingPeriod {
|
||||
id String @id @default(cuid())
|
||||
name String @unique
|
||||
|
||||
Reference in New Issue
Block a user