CheckoutMapper
in package
FinalYes
Thin passthrough like {@see CartMapper}, not an empty wrapper over an entity.
CheckoutRepository returns ready scalar data (no entity to hydrate), so the mapper only fills the missing layer of the Manager, Service, Mapper, Repository chain without changing the data shape.
Table of Contents
Properties
Methods
- __construct() : mixed
- checkout() : array<string, mixed>
- myOrders() : array<string, mixed>
- paymentMethods() : array<string, mixed>
- repeatItems() : array<string, mixed>
- setBuyers() : array<string, mixed>
- summary() : array<string, mixed>
Properties
$repository read-only
private
CheckoutRepository
$repository
Methods
__construct()
public
__construct(CheckoutRepository $repository) : mixed
Parameters
- $repository : CheckoutRepository
checkout()
public
checkout(array<string, mixed> $payload) : array<string, mixed>
Parameters
- $payload : array<string, mixed>
Return values
array<string, mixed>myOrders()
public
myOrders(int $userId, int $limit, int $offset) : array<string, mixed>
Parameters
- $userId : int
- $limit : int
- $offset : int
Return values
array<string, mixed>paymentMethods()
public
paymentMethods(int $languageId) : array<string, mixed>
Parameters
- $languageId : int
Return values
array<string, mixed>repeatItems()
public
repeatItems(int $orderId, int $userId) : array<string, mixed>
Parameters
- $orderId : int
- $userId : int
Return values
array<string, mixed>setBuyers()
public
setBuyers(int $setId, array<int, int> $userIds) : array<string, mixed>
Parameters
- $setId : int
- $userIds : array<int, int>
Return values
array<string, mixed>summary()
public
summary(int $orderId[, int|null $userId = null ]) : array<string, mixed>
Parameters
- $orderId : int
- $userId : int|null = null