- Implement discount filtering in product queries and views. - Update related request and response handling for discounts.
30 lines
821 B
PHP
30 lines
821 B
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace App\Queries\Products;
|
|
|
|
use App\Dto\ProductDto;
|
|
use Domain\Enums\ProductBrand;
|
|
use Illuminate\Contracts\Pagination\LengthAwarePaginator;
|
|
use Illuminate\Support\Collection;
|
|
|
|
final readonly class GetBoPaginatedProductsQueryOutput
|
|
{
|
|
/**
|
|
* @param LengthAwarePaginator<int, ProductDto> $products
|
|
* @param list<ProductBrand> $brands
|
|
* @param Collection<int|string, mixed> $ranges
|
|
* @param Collection<int|string, mixed> $tags
|
|
* @param Collection<int, string> $discounts
|
|
*/
|
|
public function __construct(
|
|
public LengthAwarePaginator $products,
|
|
public array $brands,
|
|
public Collection $ranges,
|
|
public Collection $tags,
|
|
public Collection $discounts,
|
|
public string $searchFields,
|
|
) {
|
|
}
|
|
}
|