Class: CheckoutRepositories
Defined in: server/checkout/repositories/index.ts:50
Holds the checkout-feature repositories and exposes a transaction() entry
point.
Uses the ambient Prisma client registered via
registerPrismaClient / initPrismaClient on @the-kaizen-labs/taproot/persistence.
Repositories route their Prisma handle through TransactionManager, so
inside transaction(fn) every this.tx.* call on any repo resolves to the
active transaction automatically.
Constructors
Constructor
new CheckoutRepositories(options?: CheckoutRepositoriesOptions): CheckoutRepositories;Defined in: server/checkout/repositories/index.ts:70
Parameters
| Parameter | Type |
|---|---|
options | CheckoutRepositoriesOptions |
Returns
CheckoutRepositories
Properties
cartItems
readonly cartItems: CartItemRepository;Defined in: server/checkout/repositories/index.ts:59
carts
readonly carts: CartRepository;Defined in: server/checkout/repositories/index.ts:58
disputes
readonly disputes: DisputeRepository;Defined in: server/checkout/repositories/index.ts:65
domainEvents
readonly domainEvents: DomainEventRepository;Defined in: server/checkout/repositories/index.ts:68
orderAdjustments
readonly orderAdjustments: OrderAdjustmentRepository;Defined in: server/checkout/repositories/index.ts:62
orderLineItems
readonly orderLineItems: OrderLineItemRepository;Defined in: server/checkout/repositories/index.ts:61
orders
readonly orders: OrderRepository;Defined in: server/checkout/repositories/index.ts:60
payments
readonly payments: PaymentRepository;Defined in: server/checkout/repositories/index.ts:63
paymentTransactions
readonly paymentTransactions: PaymentTransactionRepository;Defined in: server/checkout/repositories/index.ts:64
refundItems
readonly refundItems: RefundItemRepository;Defined in: server/checkout/repositories/index.ts:67
refundRequests
readonly refundRequests: RefundRequestRepository;Defined in: server/checkout/repositories/index.ts:66
Methods
getActorId()
getActorId(): string | null;Defined in: server/checkout/repositories/index.ts:90
Resolve the same actor source every repository uses for audit columns.
Returns
string | null
transaction()
transaction<T>(fn: (repos: CheckoutRepositories) => Promise<T>): Promise<T>;Defined in: server/checkout/repositories/index.ts:96
Type Parameters
| Type Parameter |
|---|
T |
Parameters
| Parameter | Type |
|---|---|
fn | (repos: CheckoutRepositories) => Promise<T> |
Returns
Promise<T>