src/Entity/Support.php line 12

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use App\Repository\SupportRepository;
  4. use Doctrine\ORM\Mapping as ORM;
  5. use Symfony\Component\Validator\Constraints as Assert;
  6. /**
  7.  * @ORM\Entity(repositoryClass=SupportRepository::class)
  8.  */
  9. class Support
  10. {
  11.     public function __construct()
  12.     {
  13.         $this->date = new \DateTime();
  14.     }
  15.     /**
  16.      * @ORM\Id
  17.      * @ORM\GeneratedValue
  18.      * @ORM\Column(type="integer")
  19.      */
  20.     private $id;
  21.     /**
  22.      * @Assert\NotBlank()
  23.      * @ORM\Column(type="string", length=255, nullable=true)
  24.      */
  25.     private $name;
  26.     /**
  27.      * @Assert\NotBlank()
  28.      * @ORM\Column(type="string", length=255, nullable=true)
  29.      */
  30.     private $society;
  31.     /**
  32.      * @Assert\NotBlank()
  33.      * @Assert\Email()
  34.      * @ORM\Column(type="string", length=255, nullable=true)
  35.      */
  36.     private $email;
  37.     /**
  38.      * @Assert\NotBlank()
  39.      * @ORM\Column(type="text", nullable=true)
  40.      */
  41.     private $message;
  42.     /**
  43.      * @ORM\Column(type="datetime", nullable=true)
  44.      */
  45.     private $date;
  46.     public function getId(): ?int
  47.     {
  48.         return $this->id;
  49.     }
  50.     public function getName(): ?string
  51.     {
  52.         return $this->name;
  53.     }
  54.     public function setName(?string $name): self
  55.     {
  56.         $this->name $name;
  57.         return $this;
  58.     }
  59.     public function getSociety(): ?string
  60.     {
  61.         return $this->society;
  62.     }
  63.     public function setSociety(?string $society): self
  64.     {
  65.         $this->society $society;
  66.         return $this;
  67.     }
  68.     public function getEmail(): ?string
  69.     {
  70.         return $this->email;
  71.     }
  72.     public function setEmail(?string $email): self
  73.     {
  74.         $this->email $email;
  75.         return $this;
  76.     }
  77.     public function getMessage(): ?string
  78.     {
  79.         return $this->message;
  80.     }
  81.     public function setMessage(?string $message): self
  82.     {
  83.         $this->message $message;
  84.         return $this;
  85.     }
  86.     public function getDate(): ?\DateTimeInterface
  87.     {
  88.         return $this->date;
  89.     }
  90.     public function setDate(?\DateTimeInterface $date): self
  91.     {
  92.         $this->date $date;
  93.         return $this;
  94.     }
  95. }