Files
psp_api/prisma/schema/admin/partners.prisma
T
ahasani b72e6c7194 feat: refactor ComplexPosesService to remove unused defaultInsert method and improve findAll logic
fix: update PartnersService to use 'isNot' instead of 'not' for allocation checks

refactor: enhance BusinessActivityComplexesService to validate license activation before creating a complex

fix: adjust ComplexPosesService to ensure account allocation checks are accurate and handle errors properly

refactor: modify ConsumerMiddleware to set consumerData instead of partnerData for better clarity

feat: expand SaleInvoicesService to include additional fields in the invoice selection

chore: update business-activities module to include accounts-charge module for better organization

fix: ensure ComplexPosesService correctly handles account allocation during POS creation

feat: implement PartnerBusinessActivityAccountsCharge module with create functionality for account charges

refactor: streamline getPartnerBusinessActivityAllocationLimits utility for better clarity and functionality

chore: add migration script to update database schema with necessary constraints and foreign keys

feat: create DTO for accounts charge to validate incoming data
2026-04-25 15:16:59 +03:30

35 lines
1.0 KiB
Plaintext

model PartnerAccount {
id String @id @default(ulid())
role PartnerRole
created_at DateTime @default(now()) @db.Timestamp(0)
updated_at DateTime @default(now()) @updatedAt @db.Timestamp(0)
partner_id String
partner Partner @relation(fields: [partner_id], references: [id])
account_id String @unique
account Account @relation(fields: [account_id], references: [id])
@@map("partner_accounts")
}
model Partner {
id String @id @default(ulid())
name String
code String @unique()
status PartnerStatus @default(ACTIVE)
logo_url String?
created_at DateTime @default(now()) @db.Timestamp(0)
updated_at DateTime @default(now()) @updatedAt @db.Timestamp(0)
consumers Consumer[]
partner_accounts PartnerAccount[]
license_charge_transactions LicenseChargeTransaction[]
account_quota_charge_transactions PartnerAccountQuotaChargeTransaction[]
license_renew_charge_transactions LicenseRenewChargeTransaction[]
@@map("partners")
}