src/Entity/BackOrder.php line 12

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use App\Repository\BackOrderRepository;
  4. use Doctrine\ORM\Mapping as ORM;
  5. use DateTimeImmutable;
  6. /**
  7.  * @ORM\Entity(repositoryClass=BackOrderRepository::class)
  8.  */
  9. class BackOrder
  10. {
  11.     /**
  12.      * @ORM\Id
  13.      * @ORM\GeneratedValue
  14.      * @ORM\Column(type="integer")
  15.      */
  16.     private $id;
  17.     /**
  18.      * @ORM\ManyToOne(targetEntity=Articles::class, inversedBy="backOrders")
  19.      */
  20.     private $article;
  21.     /**
  22.      * @ORM\ManyToOne(targetEntity=Establishments::class, inversedBy="backOrders")
  23.      */
  24.     private $establishment;
  25.     /**
  26.      * @ORM\Column(type="float")
  27.      */
  28.     private $quantity;
  29.     /**
  30.      * @ORM\ManyToOne(targetEntity=Users::class, inversedBy="backOrders")
  31.      */
  32.     private $user;
  33.     /**
  34.      * @ORM\Column(type="boolean")
  35.      */
  36.     private $deleted false;
  37.     /**
  38.      * @ORM\Column(type="datetime_immutable")
  39.      */
  40.     private $createdAt;
  41.     /**
  42.      * @ORM\ManyToOne(targetEntity=ShoppingCart::class, inversedBy="backOrders")
  43.      */
  44.     private $shoppingCart;
  45.     /**
  46.      * @ORM\Column(type="boolean")
  47.      */
  48.     private $userNotified false;
  49.     /**
  50.      * @ORM\Column(type="datetime_immutable", nullable=true)
  51.      */
  52.     private $deletedAt;
  53.     /**
  54.      * @ORM\Column(type="string", length=255, nullable=true)
  55.      */
  56.     private $quantityPunch;
  57.     public function __construct()
  58.     {
  59.         $this->createdAt = new DateTimeImmutable();
  60.     }
  61.     
  62.     public function getId(): ?int
  63.     {
  64.         return $this->id;
  65.     }
  66.     public function getArticle(): ?Articles
  67.     {
  68.         return $this->article;
  69.     }
  70.     public function setArticle(?Articles $article): self
  71.     {
  72.         $this->article $article;
  73.         return $this;
  74.     }
  75.     public function getEstablishment(): ?Establishments
  76.     {
  77.         return $this->establishment;
  78.     }
  79.     public function setEstablishment(?Establishments $establishment): self
  80.     {
  81.         $this->establishment $establishment;
  82.         return $this;
  83.     }
  84.     public function getQuantity(): ?float
  85.     {
  86.         return $this->quantity;
  87.     }
  88.     public function setQuantity(float $quantity): self
  89.     {
  90.         $this->quantity $quantity;
  91.         return $this;
  92.     }
  93.     public function getUser(): ?Users
  94.     {
  95.         return $this->user;
  96.     }
  97.     public function setUser(?Users $user): self
  98.     {
  99.         $this->user $user;
  100.         return $this;
  101.     }
  102.     public function isDeleted(): ?bool
  103.     {
  104.         return $this->deleted;
  105.     }
  106.     public function setDeleted(bool $deleted): self
  107.     {
  108.         $this->deleted $deleted;
  109.         return $this;
  110.     }
  111.     public function getCreatedAt(): ?\DateTimeImmutable
  112.     {
  113.         return $this->createdAt;
  114.     }
  115.     public function setCreatedAt(\DateTimeImmutable $createdAt): self
  116.     {
  117.         $this->createdAt $createdAt;
  118.         return $this;
  119.     }
  120.     public function getShoppingCart(): ?ShoppingCart
  121.     {
  122.         return $this->shoppingCart;
  123.     }
  124.     public function setShoppingCart(?ShoppingCart $shoppingCart): self
  125.     {
  126.         $this->shoppingCart $shoppingCart;
  127.         return $this;
  128.     }
  129.     public function isUserNotified(): ?bool
  130.     {
  131.         return $this->userNotified;
  132.     }
  133.     public function setUserNotified(bool $userNotified): self
  134.     {
  135.         $this->userNotified $userNotified;
  136.         return $this;
  137.     }
  138.     public function getDeletedAt(): ?\DateTimeImmutable
  139.     {
  140.         return $this->deletedAt;
  141.     }
  142.     public function setDeletedAt(?\DateTimeImmutable $deletedAt): self
  143.     {
  144.         $this->deletedAt $deletedAt;
  145.         return $this;
  146.     }
  147.     public function getQuantityPunch(): ?string
  148.     {
  149.         return $this->quantityPunch;
  150.     }
  151.     public function setQuantityPunch(?string $quantityPunch): self
  152.     {
  153.         $this->quantityPunch $quantityPunch;
  154.         return $this;
  155.     }
  156. }