<?php
namespace App\Entity\Gos\Embeddable;
use App\Enum\BufferedShopOrderStatus;
use Doctrine\ORM\Mapping as ORM;
/** @ORM\Embeddable */
final class BufferedShopOrderPart
{
/** @ORM\Column(type="boolean", options={"comment": "Sklep Buforowy GOS - zamówienie jest odpowiednie dla Sklepu Buforowego"}) */
private bool $isEligible = false;
/** @ORM\Column(type="string", length=255, nullable=true, enumType="App\Enum\BufferedShopOrderStatus", options={"comment": "Sklep Buforowy GOS - status zamówienia"}) */
private BufferedShopOrderStatus $status;
/** @ORM\Column(type="datetime_immutable", nullable=true, options={"comment": "Sklep Buforowy GOS - data eksportu"}) */
private ?\DateTimeImmutable $exportedAt;
/** @ORM\Column(type="datetime_immutable", nullable=true, options={"comment": "Sklep Buforowy GOS - data akceptacji"}) */
private ?\DateTimeImmutable $acceptedAt;
/** @ORM\Column(type="datetime_immutable", nullable=true, options={"comment": "Sklep Buforowy GOS - data wydruku"}) */
private ?\DateTimeImmutable $printedAt;
/** @ORM\Column(type="boolean", options={"comment": "Sklep Buforowy GOS - zamówienie jest priorytetowe"}) */
private bool $isPriority = false;
public function __construct()
{
$this->status = BufferedShopOrderStatus::Accepted;
$this->acceptedAt = new \DateTimeImmutable();
}
public function isEligible(): bool
{
return $this->isEligible;
}
public function setIsEligible(bool $isEligible): self
{
$this->isEligible = $isEligible;
return $this;
}
public function getStatus(): BufferedShopOrderStatus
{
return $this->status;
}
public function setStatus(BufferedShopOrderStatus $status): self
{
$this->status = $status;
return $this;
}
public function getExportedAt(): ?\DateTimeImmutable
{
return $this->exportedAt;
}
public function setExportedAt(?\DateTimeImmutable $exportedAt): self
{
$this->exportedAt = $exportedAt;
return $this;
}
public function getAcceptedAt(): ?\DateTimeImmutable
{
return $this->acceptedAt;
}
public function setAcceptedAt(?\DateTimeImmutable $acceptedAt): self
{
$this->acceptedAt = $acceptedAt;
return $this;
}
public function getPrintedAt(): ?\DateTimeImmutable
{
return $this->printedAt;
}
public function setPrintedAt(?\DateTimeImmutable $printedAt): self
{
$this->printedAt = $printedAt;
return $this;
}
public function isPriority(): bool
{
return $this->isPriority;
}
public function setIsPriority(bool $isPriority): self
{
$this->isPriority = $isPriority;
return $this;
}
}