This commit is contained in:
2024-11-27 07:48:16 +05:00
parent 7389de4c76
commit 7fadcd561f
17 changed files with 454 additions and 189 deletions

View File

@ -14,12 +14,18 @@ datasource db {
}
model User {
id String @id @default(cuid())
id String @id @default(cuid())
name String?
email String @unique
emailVerified Boolean @default(false)
firstPaymentDone Boolean @default(false)
verified Boolean @default(false)
email String? @unique
emailVerified Boolean @default(false)
firstPaymentDone Boolean @default(false)
verified Boolean @default(false)
// island String?
house_name String?
id_card String? @unique
dob DateTime?
atoll Atoll? @relation(fields: [atollId], references: [id])
island Island? @relation(fields: [islandId], references: [id])
image String?
createdAt DateTime @default(now())
@ -27,8 +33,10 @@ model User {
phoneNumber String @unique
phoneNumberVerified Boolean @default(false)
role String?
lang String?
role String?
lang String?
atollId String?
islandId String?
@@map("user")
}
@ -75,3 +83,22 @@ model Verification {
@@map("verification")
}
model Atoll {
id String @id @default(cuid())
name String
createdAt DateTime @default(now())
updatedAt DateTime @updatedAt
islands Island[]
User User[]
}
model Island {
id String @id @default(cuid())
atollId String
atoll Atoll @relation(fields: [atollId], references: [id])
name String
createdAt DateTime @default(now())
updatedAt DateTime @updatedAt
User User[]
}