src/Entity/Gos/Newsletter.php line 12

Open in your IDE?
  1. <?php
  2. namespace App\Entity\Gos;
  3. use App\Repository\Gos\NewsletterRepository;
  4. use Doctrine\ORM\Mapping as ORM;
  5. /**
  6.  * @ORM\Entity(repositoryClass=NewsletterRepository::class)
  7.  * @ORM\HasLifecycleCallbacks
  8.  */
  9. class Newsletter
  10. {
  11.     /**
  12.      * @ORM\Id
  13.      * @ORM\GeneratedValue
  14.      * @ORM\Column(type="integer")
  15.      */
  16.     private $id;
  17.     /**
  18.      * @ORM\Column(type="string", length=255)
  19.      */
  20.     private $email;
  21.     /**
  22.      * @ORM\Column(type="string", length=255)
  23.      */
  24.     private $hash;
  25.     /**
  26.      * @ORM\Column(type="datetime")
  27.      */
  28.     private $createdAt;
  29.     /**
  30.      * @ORM\Column(type="datetime", nullable=true)
  31.      */
  32.     private $updatedAt;
  33.     /**
  34.      * @ORM\Column(type="datetime", nullable=true)
  35.      */
  36.     private $dateNextSend;
  37.     /**
  38.      * @ORM\ManyToOne(targetEntity=PortalSettings::class, inversedBy="newsletters")
  39.      */
  40.     private $portalSettings;
  41.     /**
  42.      * @ORM\Column(type="boolean", nullable=true, options={"default":0})
  43.      */
  44.     private $isConfirmed false;
  45.     /**
  46.      * @ORM\Column(type="integer", nullable=true, options={"default":0})
  47.      */
  48.     private $countSendMailReminder;
  49.     /**
  50.      * @ORM\Column(type="string", length=255, nullable=true)
  51.      */
  52.     private $firstName;
  53.     /**
  54.      * @ORM\Column(type="string", length=255, nullable=true)
  55.      */
  56.     private $lastName;
  57.     /**
  58.      * @ORM\ManyToOne(targetEntity=NewsletterTemplate::class, inversedBy="newsletters")
  59.      */
  60.     private $newsletterTemplate;
  61.     /**
  62.      * @ORM\Column(type="string", length=255, nullable=true)
  63.      */
  64.     private $phone;
  65.     /**
  66.      * @ORM\Column(type="string", length=255, nullable=true)
  67.      */
  68.     private $street;
  69.     /**
  70.      * @ORM\Column(type="string", length=255, nullable=true)
  71.      */
  72.     private $postalCode;
  73.     /**
  74.      * @ORM\Column(type="string", length=255, nullable=true)
  75.      */
  76.     private $city;
  77.     /**
  78.      * @ORM\Column(type="string", length=255, nullable=true)
  79.      */
  80.     private $position;
  81.     /** @ORM\PrePersist() */
  82.     public function prePersist()
  83.     {
  84.         $this->createdAt = new \DateTime();
  85.     }
  86.     /** @ORM\PreUpdate() */
  87.     public function preUpdate()
  88.     {
  89.         $this->updatedAt = new \DateTime();
  90.     }
  91.     public function getId(): ?int
  92.     {
  93.         return $this->id;
  94.     }
  95.     public function getEmail(): ?string
  96.     {
  97.         return $this->email;
  98.     }
  99.     public function setEmail(string $email): self
  100.     {
  101.         $this->email $email;
  102.         return $this;
  103.     }
  104.     public function getHash(): ?string
  105.     {
  106.         return $this->hash;
  107.     }
  108.     public function setHash(string $hash): self
  109.     {
  110.         $this->hash $hash;
  111.         return $this;
  112.     }
  113.     public function getCreatedAt(): ?\DateTimeInterface
  114.     {
  115.         return $this->createdAt;
  116.     }
  117.     public function setCreatedAt(\DateTimeInterface $createdAt): self
  118.     {
  119.         $this->createdAt $createdAt;
  120.         return $this;
  121.     }
  122.     public function getUpdatedAt(): ?\DateTimeInterface
  123.     {
  124.         return $this->updatedAt;
  125.     }
  126.     public function setUpdatedAt(?\DateTimeInterface $updatedAt): self
  127.     {
  128.         $this->updatedAt $updatedAt;
  129.         return $this;
  130.     }
  131.     public function getDateNextSend(): ?\DateTimeInterface
  132.     {
  133.         return $this->dateNextSend;
  134.     }
  135.     public function setDateNextSend(\DateTimeInterface $dateNextSend): self
  136.     {
  137.         $this->dateNextSend $dateNextSend;
  138.         return $this;
  139.     }
  140.     public function getPortalSettings(): ?PortalSettings
  141.     {
  142.         return $this->portalSettings;
  143.     }
  144.     public function setPortalSettings(?PortalSettings $portalSettings): self
  145.     {
  146.         $this->portalSettings $portalSettings;
  147.         return $this;
  148.     }
  149.     public function getIsConfirmed(): ?bool
  150.     {
  151.         return $this->isConfirmed;
  152.     }
  153.     public function setIsConfirmed(?bool $isConfirmed): self
  154.     {
  155.         $this->isConfirmed $isConfirmed;
  156.         return $this;
  157.     }
  158.     public function getCountSendMailReminder(): ?int
  159.     {
  160.         return $this->countSendMailReminder;
  161.     }
  162.     public function setCountSendMailReminder(?int $countSendMailReminder): self
  163.     {
  164.         $this->countSendMailReminder $countSendMailReminder;
  165.         return $this;
  166.     }
  167.     public function increaseCountSendMailReminder(): self
  168.     {
  169.         $this->countSendMailReminder++;
  170.         return $this;
  171.     }
  172.     public function getFirstName(): ?string
  173.     {
  174.         return $this->firstName;
  175.     }
  176.     public function setFirstName(?string $firstName): self
  177.     {
  178.         $this->firstName $firstName;
  179.         return $this;
  180.     }
  181.     public function getLastName(): ?string
  182.     {
  183.         return $this->lastName;
  184.     }
  185.     public function setLastName(?string $lastName): self
  186.     {
  187.         $this->lastName $lastName;
  188.         return $this;
  189.     }
  190.     public function getNewsletterTemplate(): ?NewsletterTemplate
  191.     {
  192.         return $this->newsletterTemplate;
  193.     }
  194.     public function setNewsletterTemplate(?NewsletterTemplate $newsletterTemplate): self
  195.     {
  196.         $this->newsletterTemplate $newsletterTemplate;
  197.         return $this;
  198.     }
  199.     public function getPhone(): ?string
  200.     {
  201.         return $this->phone;
  202.     }
  203.     public function setPhone(?string $phone): self
  204.     {
  205.         $this->phone $phone;
  206.         return $this;
  207.     }
  208.     public function getStreet(): ?string
  209.     {
  210.         return $this->street;
  211.     }
  212.     public function setStreet(?string $street): self
  213.     {
  214.         $this->street $street;
  215.         return $this;
  216.     }
  217.     public function getPostalCode(): ?string
  218.     {
  219.         return $this->postalCode;
  220.     }
  221.     public function setPostalCode(?string $postalCode): self
  222.     {
  223.         $this->postalCode $postalCode;
  224.         return $this;
  225.     }
  226.     public function getCity(): ?string
  227.     {
  228.         return $this->city;
  229.     }
  230.     public function setCity(?string $city): self
  231.     {
  232.         $this->city $city;
  233.         return $this;
  234.     }
  235.     public function getPosition(): ?string
  236.     {
  237.         return $this->position;
  238.     }
  239.     public function setPosition(?string $position): self
  240.     {
  241.         $this->position $position;
  242.         return $this;
  243.     }
  244. }