src/Products/NotificationsBundle/Entity/ContactAttempts/WebsiteContactAttempt.php line 17

Open in your IDE?
  1. <?php
  2. namespace Products\NotificationsBundle\Entity\ContactAttempts;
  3. use Cms\ContainerBundle\Entity\Containers\GenericContainer;
  4. use Doctrine\ORM\Mapping as ORM;
  5. use Products\NotificationsBundle\Entity\AbstractContactAttempt;
  6. /**
  7.  * Class WebsiteContactAttempt
  8.  * @package Products\NotificationsBundle\Entity\ContactAttepmts
  9.  *
  10.  * @ORM\Entity(
  11.  *     repositoryClass = "Products\NotificationsBundle\Doctrine\Repository\ContactAttempts\WebsiteContactAttemptRepository",
  12.  * )
  13.  */
  14. class WebsiteContactAttempt extends AbstractServiceContactAttempt
  15. {
  16.     const DISCR 'website';
  17.     const STATUSES = [
  18.         ...self::PENDING_STATUSES,
  19.         ...self::SUCCESSFUL_STATUSES,
  20.         ...self::FAILED_STATUSES,
  21.     ];
  22.     const PENDING_STATUSES = [
  23.         ...AbstractContactAttempt::PENDING_STATUSES,
  24.     ];
  25.     const SUCCESSFUL_STATUSES = [
  26.         ...AbstractContactAttempt::SUCCESSFUL_STATUSES,
  27.     ];
  28.     const FAILED_STATUSES = [
  29.         ...AbstractContactAttempt::FAILED_STATUSES,
  30.     ];
  31.     /**
  32.      * @var GenericContainer|null
  33.      *
  34.      * @ORM\ManyToOne(
  35.      *     targetEntity = "Cms\ContainerBundle\Entity\Containers\GenericContainer",
  36.      * )
  37.      * @ORM\JoinColumn(
  38.      *     name = "department",
  39.      *     referencedColumnName = "id",
  40.      *     nullable = true,
  41.      *     onDelete = "SET NULL",
  42.      * )
  43.      */
  44.     protected ?GenericContainer $department null;
  45.     /**
  46.      * @return GenericContainer|null
  47.      */
  48.     public function getDepartment(): ?GenericContainer
  49.     {
  50.         return $this->department;
  51.     }
  52.     /**
  53.      * @param GenericContainer|null $department
  54.      * @return $this
  55.      */
  56.     public function setDepartment(?GenericContainer $department): self
  57.     {
  58.         $this->department $department;
  59.         return $this;
  60.     }
  61. }