invite model
This commit is contained in:
parent
edf9584391
commit
09c4883366
|
@ -24,6 +24,9 @@ model User {
|
|||
actions ItemAct[]
|
||||
invoices Invoice[]
|
||||
withdrawls Withdrawl[]
|
||||
invites Invite[] @relation(name: "Invites")
|
||||
invite Invite? @relation(fields: [inviteId], references: [id])
|
||||
inviteId String?
|
||||
bio Item? @relation(name: "Item", fields: [bioId], references: [id])
|
||||
bioId Int?
|
||||
msats Int @default(0)
|
||||
|
@ -45,6 +48,18 @@ model LnAuth {
|
|||
pubkey String?
|
||||
}
|
||||
|
||||
model Invite {
|
||||
id String @id @default(cuid())
|
||||
createdAt DateTime @default(now()) @map(name: "created_at")
|
||||
updatedAt DateTime @default(now()) @updatedAt @map(name: "updated_at")
|
||||
user User @relation(name: "Invites", fields: [userId], references: [id])
|
||||
userId Int
|
||||
gift Int?
|
||||
limit Int?
|
||||
revoked Boolean @default(false)
|
||||
invitees User[]
|
||||
}
|
||||
|
||||
model Message {
|
||||
id Int @id @default(autoincrement())
|
||||
text String
|
||||
|
|
Loading…
Reference in New Issue