src/Entity/Evenements.php line 13

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use App\Repository\EvenementsRepository;
  4. use Doctrine\Common\Collections\ArrayCollection;
  5. use Doctrine\Common\Collections\Collection;
  6. use Doctrine\ORM\Mapping as ORM;
  7. /**
  8.  * @ORM\Entity(repositoryClass=EvenementsRepository::class)
  9.  */
  10. class Evenements
  11. {
  12.     /**
  13.      * @ORM\Id
  14.      * @ORM\GeneratedValue
  15.      * @ORM\Column(type="integer")
  16.      */
  17.     private $id;
  18.     /**
  19.      * @ORM\Column(type="string", length=255, nullable=true)
  20.      */
  21.     private $Titre;
  22.     /**
  23.      * @ORM\Column(type="text", nullable=true)
  24.      */
  25.     private $Description;
  26.     /**
  27.      * @ORM\Column(type="string", length=255, nullable=true)
  28.      */
  29.     private $Image;
  30.     /**
  31.      * @ORM\ManyToOne(targetEntity=CategoriesEvenements::class, inversedBy="evenements")
  32.      */
  33.     private $CategoriesEvenements;
  34.     /**
  35.      * @ORM\Column(type="date", nullable=true)
  36.      */
  37.     private $Date;
  38.     /**
  39.      * @ORM\Column(type="integer", nullable=true)
  40.      */
  41.     private $Billeterie;
  42.     /**
  43.      * @ORM\Column(type="string", length=255, nullable=true)
  44.      */
  45.     private $Lieu;
  46.     /**
  47.      * @ORM\Column(type="integer", nullable=true)
  48.      */
  49.     private $NbPlaces;
  50.     /**
  51.      * @ORM\OneToMany(targetEntity=Reservations::class, mappedBy="Evenements")
  52.      */
  53.     private $reservations;
  54.     /**
  55.      * @ORM\Column(type="integer", nullable=true)
  56.      */
  57.     private $Prix;
  58.     /**
  59.      * @ORM\Column(type="integer", nullable=true)
  60.      */
  61.     private $Archive;
  62.     /**
  63.      * @ORM\Column(type="text", nullable=true)
  64.      */
  65.     private $Resume;
  66.     /**
  67.      * @ORM\Column(type="string", length=255, nullable=true)
  68.      */
  69.     private $Heure;
  70.     /**
  71.      * @ORM\ManyToOne(targetEntity=Evenements::class, inversedBy="evenements")
  72.      */
  73.     private $Evenements;
  74.     /**
  75.      * @ORM\OneToMany(targetEntity=Evenements::class, mappedBy="Evenements")
  76.      */
  77.     private $evenements;
  78.     public function __construct()
  79.     {
  80.         $this->reservations = new ArrayCollection();
  81.         $this->evenements = new ArrayCollection();
  82.     }
  83.     public function __toString()
  84.     {
  85.         return $this->getTitre();
  86.     }
  87.     public function getId(): ?int
  88.     {
  89.         return $this->id;
  90.     }
  91.     public function getTitre(): ?string
  92.     {
  93.         return $this->Titre;
  94.     }
  95.     public function setTitre(?string $Titre): self
  96.     {
  97.         $this->Titre $Titre;
  98.         return $this;
  99.     }
  100.     public function getDescription(): ?string
  101.     {
  102.         return $this->Description;
  103.     }
  104.     public function setDescription(?string $Description): self
  105.     {
  106.         $this->Description $Description;
  107.         return $this;
  108.     }
  109.     public function getImage(): ?string
  110.     {
  111.         return $this->Image;
  112.     }
  113.     public function setImage(?string $Image): self
  114.     {
  115.         $this->Image $Image;
  116.         return $this;
  117.     }
  118.     public function getCategoriesEvenements(): ?CategoriesEvenements
  119.     {
  120.         return $this->CategoriesEvenements;
  121.     }
  122.     public function setCategoriesEvenements(?CategoriesEvenements $CategoriesEvenements): self
  123.     {
  124.         $this->CategoriesEvenements $CategoriesEvenements;
  125.         return $this;
  126.     }
  127.     public function getDate(): ?\DateTimeInterface
  128.     {
  129.         return $this->Date;
  130.     }
  131.     public function setDate(?\DateTimeInterface $Date): self
  132.     {
  133.         $this->Date $Date;
  134.         return $this;
  135.     }
  136.     public function getBilleterie(): ?string
  137.     {
  138.         return $this->Billeterie;
  139.     }
  140.     public function setBilleterie(?string $Billeterie): self
  141.     {
  142.         $this->Billeterie $Billeterie;
  143.         return $this;
  144.     }
  145.     public function getLieu(): ?string
  146.     {
  147.         return $this->Lieu;
  148.     }
  149.     public function setLieu(?string $Lieu): self
  150.     {
  151.         $this->Lieu $Lieu;
  152.         return $this;
  153.     }
  154.     public function getNbPlaces(): ?int
  155.     {
  156.         return $this->NbPlaces;
  157.     }
  158.     public function setNbPlaces(?int $NbPlaces): self
  159.     {
  160.         $this->NbPlaces $NbPlaces;
  161.         return $this;
  162.     }
  163.     /**
  164.      * @return Collection<int, Reservations>
  165.      */
  166.     public function getReservations(): Collection
  167.     {
  168.         return $this->reservations;
  169.     }
  170.     public function addReservation(Reservations $reservation): self
  171.     {
  172.         if (!$this->reservations->contains($reservation)) {
  173.             $this->reservations[] = $reservation;
  174.             $reservation->setEvenements($this);
  175.         }
  176.         return $this;
  177.     }
  178.     public function removeReservation(Reservations $reservation): self
  179.     {
  180.         if ($this->reservations->removeElement($reservation)) {
  181.             // set the owning side to null (unless already changed)
  182.             if ($reservation->getEvenements() === $this) {
  183.                 $reservation->setEvenements(null);
  184.             }
  185.         }
  186.         return $this;
  187.     }
  188.     public function getPrix(): ?int
  189.     {
  190.         return $this->Prix;
  191.     }
  192.     public function setPrix(?int $Prix): self
  193.     {
  194.         $this->Prix $Prix;
  195.         return $this;
  196.     }
  197.     public function getArchive(): ?int
  198.     {
  199.         return $this->Archive;
  200.     }
  201.     public function setArchive(?int $Archive): self
  202.     {
  203.         $this->Archive $Archive;
  204.         return $this;
  205.     }
  206.     public function getResume(): ?string
  207.     {
  208.         return $this->Resume;
  209.     }
  210.     public function setResume(?string $Resume): self
  211.     {
  212.         $this->Resume $Resume;
  213.         return $this;
  214.     }
  215.     public function getHeure(): ?string
  216.     {
  217.         return $this->Heure;
  218.     }
  219.     public function setHeure(?string $Heure): self
  220.     {
  221.         $this->Heure $Heure;
  222.         return $this;
  223.     }
  224.     public function getEvenements(): ?self
  225.     {
  226.         return $this->Evenements;
  227.     }
  228.     public function setEvenements(?self $Evenements): self
  229.     {
  230.         $this->Evenements $Evenements;
  231.         return $this;
  232.     }
  233.     public function addEvenement(self $evenement): self
  234.     {
  235.         if (!$this->evenements->contains($evenement)) {
  236.             $this->evenements[] = $evenement;
  237.             $evenement->setEvenements($this);
  238.         }
  239.         return $this;
  240.     }
  241.     public function removeEvenement(self $evenement): self
  242.     {
  243.         if ($this->evenements->removeElement($evenement)) {
  244.             // set the owning side to null (unless already changed)
  245.             if ($evenement->getEvenements() === $this) {
  246.                 $evenement->setEvenements(null);
  247.             }
  248.         }
  249.         return $this;
  250.     }
  251. }