src/Entity/ApiMailField.php line 16

Open in your IDE?
  1. <?php
  2.     namespace App\Entity;
  3.     use App\Repository\ApiMailFieldRepository;
  4.     use App\Services\Common\Email\MailFields;
  5.     use Doctrine\ORM\Mapping as ORM;
  6.     use Symfony\Component\Validator\Constraints as Assert;
  7.     /**
  8.      * Field qui serve à créer les templates dans le BACK
  9.      * @ORM\Entity(repositoryClass=ApiMailFieldRepository::class)
  10.      *
  11.      * @deprecated {@see MailFields}
  12.      */
  13.     class ApiMailField
  14.     {
  15.         /**
  16.          * @ORM\Id
  17.          * @ORM\GeneratedValue
  18.          * @ORM\Column(type="integer")
  19.          */
  20.         private ?int $id NULL;
  21.         /**
  22.          * @Assert\NotBlank
  23.          * @Assert\Length(
  24.          *      min = 1,
  25.          *      max = 64,
  26.          * )
  27.          * @ORM\Column(type="string", length=64)
  28.          */
  29.         private string $slug;
  30.         /**
  31.          * @Assert\NotBlank
  32.          * @ORM\Column(type="string", length=255)
  33.          */
  34.         private string $name;
  35.         /**
  36.          * @Assert\NotBlank
  37.          * @Assert\Length(
  38.          *      min = 1,
  39.          *      max = 64,
  40.          * )
  41.          * @ORM\Column(type="string", length=64)
  42.          */
  43.         private string $category;
  44.         public function getId(): ?int
  45.         {
  46.             return $this->id;
  47.         }
  48.         public function getSlug(): string
  49.         {
  50.             return $this->slug;
  51.         }
  52.         public function setSlug(string $slug): self
  53.         {
  54.             $this->slug $slug;
  55.             return $this;
  56.         }
  57.         public function getName(): string
  58.         {
  59.             return $this->name;
  60.         }
  61.         public function setName(string $name): self
  62.         {
  63.             $this->name $name;
  64.             return $this;
  65.         }
  66.         public function getCategory(): string
  67.         {
  68.             return $this->category;
  69.         }
  70.         public function setCategory(string $category): self
  71.         {
  72.             $this->category $category;
  73.             return $this;
  74.         }
  75.     }