Skip to content

Open-source event management and ticket selling platform — perfect for concerts, conferences, and everything in between 🎟️ If you find this project helpful, please consider giving us a star ⭐️

665 B
Raw Blame
<?php

namespace HiEvents\Resources\EventOccurrence;

use HiEvents\Services\Application\Handlers\EventOccurrence\DTO\OccurrenceProductAvailabilityDTO;
use Illuminate\Http\Request;
use Illuminate\Http\Resources\Json\JsonResource;

/**
 * @mixin OccurrenceProductAvailabilityDTO
 */
class OccurrenceProductAvailabilityResource extends JsonResource
{
    public function toArray(Request $request): array
    {
        return [
            'product_id' => $this->product_id,
            'product_price_id' => $this->product_price_id,
            'quantity_sold' => $this->quantity_sold,
            'quantity_available' => $this->quantity_available,
        ];
    }
}