src/Entity/Gos/ProductVariantReviewNotification.php line 11

Open in your IDE?
  1. <?php
  2. namespace App\Entity\Gos;
  3. use App\Repository\ProductVariantReviewNotificationRepository;
  4. use Doctrine\ORM\Mapping as ORM;
  5. /**
  6.  * @ORM\Entity(repositoryClass=ProductVariantReviewNotificationRepository::class)
  7.  */
  8. class ProductVariantReviewNotification
  9. {
  10.     public const FAIL_COUNT_LIMIT 5;
  11.     public const STATUS_SENT 0;
  12.     public const STATUS_FAILED 1;
  13.     public const STATUS_ORDER_NOT_PAID 2;
  14.     /**
  15.      * @ORM\Id
  16.      * @ORM\GeneratedValue
  17.      * @ORM\Column(type="integer")
  18.      */
  19.     private $id;
  20.     /**
  21.      * @ORM\OneToOne(targetEntity=Orders::class, inversedBy="productVariantsReviewNotification", cascade={"persist", "remove"})
  22.      * @ORM\JoinColumn(nullable=false)
  23.      */
  24.     private $orders;
  25.     /**
  26.      * @ORM\Column(type="datetime", nullable=true)
  27.      */
  28.     private $sentAt;
  29.     /**
  30.      * @ORM\Column(type="string", length=255, nullable=true)
  31.      */
  32.     private $status;
  33.     /**
  34.      * @ORM\Column(type="integer", options={"default": 0})
  35.      */
  36.     private $failCount 0;
  37.     public function getId(): ?int
  38.     {
  39.         return $this->id;
  40.     }
  41.     public function getOrders(): Orders
  42.     {
  43.         return $this->orders;
  44.     }
  45.     public function setOrders(Orders $orders): self
  46.     {
  47.         $this->orders $orders;
  48.         return $this;
  49.     }
  50.     public function getSentAt(): ?\DateTimeInterface
  51.     {
  52.         return $this->sentAt;
  53.     }
  54.     public function setSentAt(\DateTimeInterface $sentAt): self
  55.     {
  56.         $this->sentAt $sentAt;
  57.         return $this;
  58.     }
  59.     public function getStatus(): ?string
  60.     {
  61.         return $this->status;
  62.     }
  63.     public function setStatus(?string $status): self
  64.     {
  65.         $this->status $status;
  66.         return $this;
  67.     }
  68.     public function getFailCount(): int
  69.     {
  70.         return $this->failCount;
  71.     }
  72.     public function setFailCount(int $failCount): self
  73.     {
  74.         $this->failCount $failCount;
  75.         return $this;
  76.     }
  77.     public function increaseFailCount(): self
  78.     {
  79.         $this->failCount++;
  80.         return $this;
  81.     }
  82. }