2026-03-07 11:25:11 +03:30
|
|
|
model License {
|
2026-04-16 22:19:20 +03:30
|
|
|
id String @id @default(uuid())
|
|
|
|
|
|
|
|
|
|
created_at DateTime @default(now()) @db.Timestamp(0)
|
|
|
|
|
updated_at DateTime @updatedAt() @db.Timestamp(0)
|
|
|
|
|
|
|
|
|
|
charged_license_transaction_id String
|
|
|
|
|
charged_license_transaction ChargedLicenseTransactions @relation(fields: [charged_license_transaction_id], references: [id])
|
|
|
|
|
|
|
|
|
|
activated_license ActivatedLicense?
|
|
|
|
|
|
|
|
|
|
@@map("licenses")
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
model ActivatedLicense {
|
|
|
|
|
id String @id @unique() @default(uuid())
|
2026-03-07 11:25:11 +03:30
|
|
|
starts_at DateTime
|
|
|
|
|
expires_at DateTime
|
|
|
|
|
|
2026-03-14 16:26:44 +03:30
|
|
|
created_at DateTime @default(now()) @db.Timestamp(0)
|
|
|
|
|
updated_at DateTime @updatedAt() @db.Timestamp(0)
|
|
|
|
|
|
2026-04-16 22:19:20 +03:30
|
|
|
license_id String @unique
|
|
|
|
|
license License @relation(fields: [license_id], references: [id])
|
2026-03-07 11:25:11 +03:30
|
|
|
|
2026-04-16 22:19:20 +03:30
|
|
|
consumer_id String
|
2026-04-06 21:12:07 +03:30
|
|
|
consumer Consumer @relation(fields: [consumer_id], references: [id])
|
2026-03-07 11:25:11 +03:30
|
|
|
|
2026-04-16 22:19:20 +03:30
|
|
|
@@map("activated_licenses")
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
model ChargedLicenseTransactions {
|
|
|
|
|
id String @id @default(uuid())
|
|
|
|
|
activation_expires_at DateTime
|
2026-04-22 21:55:40 +03:30
|
|
|
tracking_code String @unique()
|
2026-04-16 22:19:20 +03:30
|
|
|
|
|
|
|
|
created_at DateTime @default(now()) @db.Timestamp(0)
|
|
|
|
|
updated_at DateTime @updatedAt() @db.Timestamp(0)
|
|
|
|
|
|
|
|
|
|
partner_id String
|
|
|
|
|
partner Partner @relation(fields: [partner_id], references: [id])
|
|
|
|
|
|
|
|
|
|
licenses License[]
|
|
|
|
|
|
|
|
|
|
@@map("charged_license_transactions")
|
2026-03-07 11:25:11 +03:30
|
|
|
}
|