backup page done
This commit is contained in:
@@ -27,8 +27,9 @@ model User {
|
||||
appointments Appointment[]
|
||||
claims Claim[]
|
||||
insuranceCredentials InsuranceCredential[]
|
||||
// reverse relations
|
||||
updatedPayments Payment[] @relation("PaymentUpdatedBy")
|
||||
backups DatabaseBackup[]
|
||||
notifications Notification[]
|
||||
}
|
||||
|
||||
model Patient {
|
||||
@@ -258,3 +259,35 @@ enum PaymentMethod {
|
||||
CARD
|
||||
OTHER
|
||||
}
|
||||
|
||||
model DatabaseBackup {
|
||||
id Int @id @default(autoincrement())
|
||||
userId Int
|
||||
createdAt DateTime @default(now())
|
||||
|
||||
user User @relation(fields: [userId], references: [id], onDelete: Cascade)
|
||||
|
||||
@@index([userId])
|
||||
@@index([createdAt])
|
||||
}
|
||||
|
||||
model Notification {
|
||||
id Int @id @default(autoincrement())
|
||||
userId Int
|
||||
type NotificationTypes
|
||||
message String
|
||||
createdAt DateTime @default(now())
|
||||
read Boolean @default(false)
|
||||
|
||||
user User @relation(fields: [userId], references: [id], onDelete: Cascade)
|
||||
|
||||
@@index([userId])
|
||||
@@index([createdAt])
|
||||
}
|
||||
|
||||
enum NotificationTypes {
|
||||
BACKUP
|
||||
CLAIM
|
||||
PAYMENT
|
||||
ETC
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user