src/Entity/Booking.php line 9

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use App\Repository\BookingRepository;
  4. use Doctrine\ORM\Mapping as ORM;
  5. #[ORM\Entity(repositoryClassBookingRepository::class)]
  6. class Booking
  7. {
  8.     #[ORM\Id]
  9.     #[ORM\GeneratedValue]
  10.     #[ORM\Column(type'integer')]
  11.     private $id;
  12.     #[ORM\ManyToOne(targetEntityCourse::class, inversedBy'bookings')]
  13.     private $course;
  14.     #[ORM\ManyToOne(targetEntityTrainee::class, inversedBy'bookings')]
  15.     private $trainee;
  16.     #[ORM\Column(type'string'length255)]
  17.     private $begin;
  18.     #[ORM\Column(type'string'length255)]
  19.     private $end;
  20.     #[ORM\Column(type'string'length255)]
  21.     private $adult;
  22.     #[ORM\Column(type'string'length255)]
  23.     private $teen;
  24.     #[ORM\Column(type'string'length255)]
  25.     private $child;
  26.     #[ORM\Column(type'string'length255)]
  27.     private $total;
  28.     #[ORM\Column(type'datetime')]
  29.     private $askedAt;
  30.     #[ORM\Column(type'string'length255)]
  31.     private $status;
  32.     #[ORM\Column(type'string'length255nullabletrue)]
  33.     private $paymentMethod;
  34.     #[ORM\Column(type'boolean'nullabletrue)]
  35.     private $isPaid;
  36.     #[ORM\OneToOne(targetEntityPaymentRequest::class, mappedBy'booking'cascade: ['persist''remove'])]
  37.     private $paymentRequest;
  38.     #[ORM\Column(type'string'length255)]
  39.     private $week;
  40.     #[ORM\OneToOne(targetEntityNote::class, mappedBy'booking'cascade: ['persist''remove'])]
  41.     private $note;
  42.     #[ORM\Column(type'string'length255nullabletrue)]
  43.     private $reason;
  44.     #[ORM\Column(type'boolean'nullabletrue)]
  45.     private $isNoted;
  46.     #[ORM\Column(type'string'length255nullabletrue)]
  47.     private $ref;
  48.     #[ORM\Column(type'string'length255)]
  49.     private $month;
  50.     #[ORM\Column(type'string'length255)]
  51.     private $year;
  52.     public function getId(): ?int
  53.     {
  54.         return $this->id;
  55.     }
  56.     public function getCourse(): ?Course
  57.     {
  58.         return $this->course;
  59.     }
  60.     public function setCourse(?Course $course): self
  61.     {
  62.         $this->course $course;
  63.         return $this;
  64.     }
  65.     public function getTrainee(): ?Trainee
  66.     {
  67.         return $this->trainee;
  68.     }
  69.     public function setTrainee(?Trainee $trainee): self
  70.     {
  71.         $this->trainee $trainee;
  72.         return $this;
  73.     }
  74.     public function getBegin(): ?string
  75.     {
  76.         return $this->begin;
  77.     }
  78.     public function setBegin(string $begin): self
  79.     {
  80.         $this->begin $begin;
  81.         return $this;
  82.     }
  83.     public function getEnd(): ?string
  84.     {
  85.         return $this->end;
  86.     }
  87.     public function setEnd(string $end): self
  88.     {
  89.         $this->end $end;
  90.         return $this;
  91.     }
  92.     public function getAdult(): ?string
  93.     {
  94.         return $this->adult;
  95.     }
  96.     public function setAdult(string $adult): self
  97.     {
  98.         $this->adult $adult;
  99.         return $this;
  100.     }
  101.     public function getTeen(): ?string
  102.     {
  103.         return $this->teen;
  104.     }
  105.     public function setTeen(string $teen): self
  106.     {
  107.         $this->teen $teen;
  108.         return $this;
  109.     }
  110.     public function getChild(): ?string
  111.     {
  112.         return $this->child;
  113.     }
  114.     public function setChild(string $child): self
  115.     {
  116.         $this->child $child;
  117.         return $this;
  118.     }
  119.     public function getTotal(): ?string
  120.     {
  121.         return $this->total;
  122.     }
  123.     public function setTotal(string $total): self
  124.     {
  125.         $this->total $total;
  126.         return $this;
  127.     }
  128.     public function getAskedAt(): ?\DateTimeInterface
  129.     {
  130.         return $this->askedAt;
  131.     }
  132.     public function setAskedAt(\DateTimeInterface $askedAt): self
  133.     {
  134.         $this->askedAt $askedAt;
  135.         return $this;
  136.     }
  137.     public function getStatus(): ?string
  138.     {
  139.         return $this->status;
  140.     }
  141.     public function setStatus(string $status): self
  142.     {
  143.         $this->status $status;
  144.         return $this;
  145.     }
  146.     public function getPaymentMethod(): ?string
  147.     {
  148.         return $this->paymentMethod;
  149.     }
  150.     public function setPaymentMethod(?string $paymentMethod): self
  151.     {
  152.         $this->paymentMethod $paymentMethod;
  153.         return $this;
  154.     }
  155.     public function getIsPaid(): ?bool
  156.     {
  157.         return $this->isPaid;
  158.     }
  159.     public function setIsPaid(?bool $isPaid): self
  160.     {
  161.         $this->isPaid $isPaid;
  162.         return $this;
  163.     }
  164.     public function getPaymentRequest(): ?PaymentRequest
  165.     {
  166.         return $this->paymentRequest;
  167.     }
  168.     public function setPaymentRequest(?PaymentRequest $paymentRequest): self
  169.     {
  170.         // unset the owning side of the relation if necessary
  171.         if ($paymentRequest === null && $this->paymentRequest !== null) {
  172.             $this->paymentRequest->setBooking(null);
  173.         }
  174.         // set the owning side of the relation if necessary
  175.         if ($paymentRequest !== null && $paymentRequest->getBooking() !== $this) {
  176.             $paymentRequest->setBooking($this);
  177.         }
  178.         $this->paymentRequest $paymentRequest;
  179.         return $this;
  180.     }
  181.     public function getWeek(): ?string
  182.     {
  183.         return $this->week;
  184.     }
  185.     public function setWeek(string $week): self
  186.     {
  187.         $this->week $week;
  188.         return $this;
  189.     }
  190.     public function getNote(): ?Note
  191.     {
  192.         return $this->note;
  193.     }
  194.     public function setNote(?Note $note): self
  195.     {
  196.         // unset the owning side of the relation if necessary
  197.         if ($note === null && $this->note !== null) {
  198.             $this->note->setBooking(null);
  199.         }
  200.         // set the owning side of the relation if necessary
  201.         if ($note !== null && $note->getBooking() !== $this) {
  202.             $note->setBooking($this);
  203.         }
  204.         $this->note $note;
  205.         return $this;
  206.     }
  207.     public function getReason(): ?string
  208.     {
  209.         return $this->reason;
  210.     }
  211.     public function setReason(?string $reason): self
  212.     {
  213.         $this->reason $reason;
  214.         return $this;
  215.     }
  216.     public function getIsNoted(): ?bool
  217.     {
  218.         return $this->isNoted;
  219.     }
  220.     public function setIsNoted(?bool $isNoted): self
  221.     {
  222.         $this->isNoted $isNoted;
  223.         return $this;
  224.     }
  225.     public function getRef(): ?string
  226.     {
  227.         return $this->ref;
  228.     }
  229.     public function setRef(?string $ref): self
  230.     {
  231.         $this->ref $ref;
  232.         return $this;
  233.     }
  234.     public function getMonth(): ?string
  235.     {
  236.         return $this->month;
  237.     }
  238.     public function setMonth(string $month): self
  239.     {
  240.         $this->month $month;
  241.         return $this;
  242.     }
  243.     public function getYear(): ?string
  244.     {
  245.         return $this->year;
  246.     }
  247.     public function setYear(string $year): self
  248.     {
  249.         $this->year $year;
  250.         return $this;
  251.     }
  252. }