src/Entity/DocumentCategoryTranslation.php line 14

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use App\Repository\DocumentCategoryTranslationRepository;
  4. use Doctrine\ORM\Mapping as ORM;
  5. use Gedmo\Mapping\Annotation as Gedmo;
  6. use Knp\DoctrineBehaviors\Contract\Entity\TranslationInterface;
  7. use Knp\DoctrineBehaviors\Model\Translatable\TranslationTrait;
  8. /**
  9.  * @ORM\Entity(repositoryClass=DocumentCategoryTranslationRepository::class)
  10.  */
  11. class DocumentCategoryTranslation implements TranslationInterface
  12. {
  13.     use TranslationTrait;
  14.     /**
  15.      * @ORM\Id
  16.      * @ORM\GeneratedValue
  17.      * @ORM\Column(type="integer")
  18.      */
  19.     private $id;
  20.     /**
  21.      * @ORM\Column(type="string", length=255, nullable=true)
  22.      */
  23.     private $title;
  24.     /**
  25.      * @Gedmo\Slug(fields={"title"})
  26.      * @ORM\Column(type="string", length=255, nullable=true)
  27.      */
  28.     private $slug;
  29.     public function getId(): ?int
  30.     {
  31.         return $this->id;
  32.     }
  33.     public function getTitle(): ?string
  34.     {
  35.         return $this->title;
  36.     }
  37.     public function setTitle(?string $title): self
  38.     {
  39.         $this->title $title;
  40.         return $this;
  41.     }
  42.     public function getSlug(): ?string
  43.     {
  44.         return $this->slug;
  45.     }
  46.     public function setSlug(?string $slug): self
  47.     {
  48.         $this->slug $slug;
  49.         return $this;
  50.     }
  51. }