User role access.

This commit is contained in:
charles-gauthereau
2024-11-23 16:05:00 +01:00
parent 9b38d68d51
commit e3fe6d1c80
10 changed files with 144 additions and 56 deletions
+7 -1
View File
@@ -59,7 +59,7 @@ model User {
email String? @unique
emailVerified DateTime? @map("email_verified")
image String?
role String?
role Role
password String?
authMethod String? @map("auth_method")
createdAt DateTime @default(now()) @map("created_at")
@@ -71,6 +71,12 @@ model User {
@@map("users")
}
enum Role {
pending
user
admin
}
model Agent {
id String @id @default(cuid())
slug String @unique