CustomerBookingEventPeriod.php
6 months ago
CustomerBookingEventTicket.php
6 months ago
Event.php
3 months ago
EventPeriod.php
6 months ago
EventTag.php
2 months ago
EventTicket.php
6 months ago
CustomerBookingEventPeriod.php
88 lines
| 1 | <?php |
| 2 | |
| 3 | /** |
| 4 | * @copyright © Melograno Ventures. All rights reserved. |
| 5 | * @licence See LICENCE.md for license details. |
| 6 | */ |
| 7 | |
| 8 | namespace AmeliaBooking\Domain\Entity\Booking\Event; |
| 9 | |
| 10 | use AmeliaBooking\Domain\ValueObjects\Number\Integer\Id; |
| 11 | |
| 12 | /** |
| 13 | * Class CustomerBookingEventPeriod |
| 14 | * |
| 15 | * @package AmeliaBooking\Domain\Entity\Booking\Event |
| 16 | */ |
| 17 | class CustomerBookingEventPeriod |
| 18 | { |
| 19 | /** @var Id */ |
| 20 | private $id; |
| 21 | |
| 22 | /** @var Id */ |
| 23 | private $customerBookingId; |
| 24 | |
| 25 | /** @var Id */ |
| 26 | protected $eventPeriodId; |
| 27 | |
| 28 | /** |
| 29 | * @return Id |
| 30 | */ |
| 31 | public function getId() |
| 32 | { |
| 33 | return $this->id; |
| 34 | } |
| 35 | |
| 36 | /** |
| 37 | * @param Id $id |
| 38 | */ |
| 39 | public function setId(Id $id) |
| 40 | { |
| 41 | $this->id = $id; |
| 42 | } |
| 43 | |
| 44 | /** |
| 45 | * @return Id |
| 46 | */ |
| 47 | public function getEventPeriodId() |
| 48 | { |
| 49 | return $this->eventPeriodId; |
| 50 | } |
| 51 | |
| 52 | /** |
| 53 | * @param Id $eventPeriodId |
| 54 | */ |
| 55 | public function setEventPeriodId(Id $eventPeriodId) |
| 56 | { |
| 57 | $this->eventPeriodId = $eventPeriodId; |
| 58 | } |
| 59 | |
| 60 | /** |
| 61 | * @return Id |
| 62 | */ |
| 63 | public function getCustomerBookingId() |
| 64 | { |
| 65 | return $this->customerBookingId; |
| 66 | } |
| 67 | |
| 68 | /** |
| 69 | * @param Id $customerBookingId |
| 70 | */ |
| 71 | public function setCustomerBookingId(Id $customerBookingId) |
| 72 | { |
| 73 | $this->customerBookingId = $customerBookingId; |
| 74 | } |
| 75 | |
| 76 | /** |
| 77 | * @return array |
| 78 | */ |
| 79 | public function toArray() |
| 80 | { |
| 81 | return [ |
| 82 | 'id' => $this->getId() ? $this->getId()->getValue() : null, |
| 83 | 'eventPeriodId' => $this->getEventPeriodId() ? $this->getEventPeriodId()->getValue() : null, |
| 84 | 'customerBookingId' => $this->getCustomerBookingId() ? $this->getCustomerBookingId()->getValue() : null |
| 85 | ]; |
| 86 | } |
| 87 | } |
| 88 |