src/Entity/SectionTitle.php line 12

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use App\Repository\SectionTitleRepository;
  4. use App\Traits\CommonTrt;
  5. use Doctrine\ORM\Mapping as ORM;
  6. /**
  7.  * @ORM\Entity(repositoryClass=SectionTitleRepository::class)
  8.  */
  9. class SectionTitle
  10. {
  11.     use CommonTrt;
  12.     /**
  13.      * @ORM\Id
  14.      * @ORM\GeneratedValue
  15.      * @ORM\Column(type="integer")
  16.      */
  17.     private $id;
  18.     /**
  19.      * @ORM\Column(type="string", length=255)
  20.      */
  21.     private $title;
  22.     /**
  23.      * @ORM\Column(type="text", nullable=true)
  24.      */
  25.     private $summary;
  26.     /**
  27.      * @ORM\Column(type="string", length=255, nullable=true)
  28.      */
  29.     private $image;
  30.     /**
  31.      * @ORM\ManyToOne(targetEntity=Lang::class, inversedBy="sectionTitles")
  32.      */
  33.     private $langue;
  34.     public function getId(): ?int
  35.     {
  36.         return $this->id;
  37.     }
  38.     public function getTitle(): ?string
  39.     {
  40.         return $this->title;
  41.     }
  42.     public function setTitle(string $title): self
  43.     {
  44.         $this->title = $title;
  45.         return $this;
  46.     }
  47.     public function getSummary(): ?string
  48.     {
  49.         return $this->summary;
  50.     }
  51.     public function setSummary(?string $summary): self
  52.     {
  53.         $this->summary = $summary;
  54.         return $this;
  55.     }
  56.     public function getImage(): ?string
  57.     {
  58.         return $this->image;
  59.     }
  60.     public function setImage(?string $image): self
  61.     {
  62.         $this->image = $image;
  63.         return $this;
  64.     }
  65.    public function __toString()
  66.    {
  67.        return $this->title;
  68.    }
  69. }