src/Entity/Offre.php line 11

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use App\Repository\OffreRepository;
  4. use Doctrine\ORM\Mapping as ORM;
  5. /**
  6.  * @ORM\Entity(repositoryClass=OffreRepository::class)
  7.  */
  8. class Offre
  9. {
  10.     /**
  11.      * @ORM\Id
  12.      * @ORM\GeneratedValue
  13.      * @ORM\Column(type="integer")
  14.      */
  15.     private $id;
  16.     /**
  17.      * @ORM\Column(type="string", length=255)
  18.      */
  19.     private $title;
  20.     /**
  21.      * @ORM\Column(type="string", length=255, nullable=true)
  22.      */
  23.     private $subtitle;
  24.     /**
  25.      * @ORM\Column(type="datetime")
  26.      */
  27.     private $createdAt;
  28.     /**
  29.      * @ORM\Column(type="text")
  30.      */
  31.     private $content;
  32.     /**
  33.      * @ORM\Column(type="string", length=255)
  34.      */
  35.     private $slug;
  36.     /**
  37.      * @ORM\Column(type="boolean")
  38.      */
  39.     private $isEnabled true;
  40.     /**
  41.      * @ORM\Column(type="string", length=255, nullable=true)
  42.      */
  43.     private $image;
  44.     /**
  45.      * @ORM\Column(type="string", length=255, nullable=true)
  46.      */
  47.     private $file;
  48.     /**
  49.      * @ORM\ManyToOne(targetEntity=Office::class, inversedBy="offres")
  50.      * @ORM\JoinColumn(nullable=false)
  51.      */
  52.     private $lieu;
  53.     public function getId(): ?int
  54.     {
  55.         return $this->id;
  56.     }
  57.     public function getTitle(): ?string
  58.     {
  59.         return $this->title;
  60.     }
  61.     public function setTitle(string $title): self
  62.     {
  63.         $this->title $title;
  64.         return $this;
  65.     }
  66.     public function getSubtitle(): ?string
  67.     {
  68.         return $this->subtitle;
  69.     }
  70.     public function setSubtitle(?string $subtitle): self
  71.     {
  72.         $this->subtitle $subtitle;
  73.         return $this;
  74.     }
  75.     public function getCreatedAt(): ?\DateTimeInterface
  76.     {
  77.         return $this->createdAt;
  78.     }
  79.     public function setCreatedAt(\DateTimeInterface $createdAt): self
  80.     {
  81.         $this->createdAt $createdAt;
  82.         return $this;
  83.     }
  84.     public function getContent(): ?string
  85.     {
  86.         return $this->content;
  87.     }
  88.     public function setContent(string $content): self
  89.     {
  90.         $this->content $content;
  91.         return $this;
  92.     }
  93.     public function getSlug(): ?string
  94.     {
  95.         return $this->slug;
  96.     }
  97.     public function setSlug(string $slug): self
  98.     {
  99.         $this->slug $slug;
  100.         return $this;
  101.     }
  102.     public function isIsEnabled(): ?bool
  103.     {
  104.         return $this->isEnabled;
  105.     }
  106.     public function setIsEnabled(bool $isEnabled): self
  107.     {
  108.         $this->isEnabled $isEnabled;
  109.         return $this;
  110.     }
  111.     public function getImage(): ?string
  112.     {
  113.         return $this->image;
  114.     }
  115.     public function setImage(?string $image): self
  116.     {
  117.         $this->image $image;
  118.         return $this;
  119.     }
  120.     public function getFile(): ?string
  121.     {
  122.         return $this->file;
  123.     }
  124.     public function setFile(?string $file): self
  125.     {
  126.         $this->file $file;
  127.         return $this;
  128.     }
  129.     public function getLieu(): ?Office
  130.     {
  131.         return $this->lieu;
  132.     }
  133.     public function setLieu(?Office $lieu): self
  134.     {
  135.         $this->lieu $lieu;
  136.         return $this;
  137.     }
  138.     public function __toString()
  139.     {
  140.         return $this->getTitle();
  141.     }
  142. }