2024-11-16 16:24:23 +11:00
|
|
|
model User {
|
|
|
|
|
id String @id @default(uuid())
|
|
|
|
|
username String @unique
|
|
|
|
|
admin Boolean @default(false)
|
2025-03-14 12:22:08 +11:00
|
|
|
enabled Boolean @default(true)
|
2024-11-16 16:24:23 +11:00
|
|
|
|
2025-05-08 19:42:46 -04:00
|
|
|
email String
|
|
|
|
|
displayName String
|
|
|
|
|
profilePictureObjectId String // Object
|
2024-11-16 16:24:23 +11:00
|
|
|
|
2026-01-13 15:32:39 +11:00
|
|
|
authMecs LinkedAuthMec[]
|
|
|
|
|
mfas LinkedMFAMec[]
|
|
|
|
|
|
2025-01-19 16:46:43 +11:00
|
|
|
clients Client[]
|
2024-11-16 19:41:19 +11:00
|
|
|
notifications Notification[]
|
2025-01-19 16:46:43 +11:00
|
|
|
collections Collection[]
|
2025-03-10 11:39:45 +11:00
|
|
|
articles Article[]
|
2025-02-04 13:15:34 +11:00
|
|
|
|
2025-04-03 19:15:33 -04:00
|
|
|
tokens APIToken[]
|
|
|
|
|
sessions Session[]
|
2025-04-01 21:08:57 +11:00
|
|
|
|
2025-05-08 11:38:09 -04:00
|
|
|
saves SaveSlot[]
|
|
|
|
|
screenshots Screenshot[]
|
2025-05-27 12:30:20 -04:00
|
|
|
playtime Playtime[]
|
2026-08-01 18:50:15 -07:00
|
|
|
|
|
|
|
|
groups UserGroup[]
|
2024-11-16 19:41:19 +11:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
model Notification {
|
|
|
|
|
id String @id @default(uuid())
|
|
|
|
|
|
2025-05-14 15:40:55 -04:00
|
|
|
nonce String?
|
2024-11-16 19:41:19 +11:00
|
|
|
|
|
|
|
|
userId String
|
2025-06-08 05:49:11 +01:00
|
|
|
user User @relation(fields: [userId], references: [id], onDelete: Cascade)
|
2025-05-15 14:55:05 +10:00
|
|
|
acls String[]
|
2024-11-16 19:41:19 +11:00
|
|
|
|
2025-01-19 16:46:43 +11:00
|
|
|
created DateTime @default(now())
|
2024-11-16 19:41:19 +11:00
|
|
|
title String
|
|
|
|
|
description String
|
|
|
|
|
actions String[]
|
|
|
|
|
|
|
|
|
|
read Boolean @default(false)
|
2025-05-14 15:40:55 -04:00
|
|
|
|
|
|
|
|
@@unique([userId, nonce])
|
2024-11-16 19:41:19 +11:00
|
|
|
}
|