src/Entity/System/FutureStock.php line 12

Open in your IDE?
  1. <?php
  2. namespace App\Entity\System;
  3. use Doctrine\ORM\Mapping as ORM;
  4. /**
  5.  * @ORM\Entity(repositoryClass="App\Repository\System\FutureStockRepository")
  6.  *
  7.  * @ORM\Table(name="ps_future_stock")
  8.  */
  9. class FutureStock
  10. {
  11.     /**
  12.      * @var int
  13.      *
  14.      * @ORM\Id
  15.      *
  16.      * @ORM\GeneratedValue(strategy="AUTO")
  17.      *
  18.      * @ORM\Column(type="integer", name="id_future_stock")
  19.      */
  20.     private $id;
  21.     /**
  22.      * @var \DateTime|null
  23.      *
  24.      * @ORM\Column(type="datetime", nullable=true)
  25.      */
  26.     private $dateNext;
  27.     /**
  28.      * @var int
  29.      *
  30.      * @ORM\Column(type="integer", options={"default":0})
  31.      */
  32.     private $quantity;
  33.     /**
  34.      * @var int|null
  35.      *
  36.      * @ORM\Column(type="integer", length=11, nullable=true, name="id_purcharse_line")
  37.      */
  38.     private $purchaseLineId;
  39.     /**
  40.      * @var int
  41.      *
  42.      * @ORM\Column(type="integer", name="id_product", length=11)
  43.      */
  44.     private $productId;
  45.     /**
  46.      * @var string|null
  47.      *
  48.      * @ORM\Column(type="string", nullable=true, options={"default":"0"}, length=50)
  49.      */
  50.     private $purchaseOrder;
  51.     /**
  52.      * @var bool|null
  53.      *
  54.      * @ORM\Column(type="boolean", nullable=true, options={"default":0}, columnDefinition="tinyint(1)")
  55.      */
  56.     private $purchaseConfirmed;
  57.     /**
  58.      * @var bool|null
  59.      *
  60.      * @ORM\Column(type="boolean", nullable=true, options={"default":0}, columnDefinition="tinyint(1)")
  61.      */
  62.     private $activeStock;
  63.     /**
  64.      * @var ProductAttribute
  65.      *
  66.      * @ORM\OneToOne(targetEntity="ProductAttribute", inversedBy="futureStock")
  67.      *
  68.      * @ORM\JoinColumn(name="id_product_attribute", referencedColumnName="id_product_attribute")
  69.      */
  70.     private $productAttribute;
  71.     /**
  72.      * @var Product
  73.      *
  74.      * @ORM\ManyToOne(targetEntity="App\Entity\System\Product", inversedBy="futureStocks")
  75.      *
  76.      * @ORM\JoinColumn(referencedColumnName="id_product", name="id_product")
  77.      */
  78.     private $product;
  79.     public function __construct()
  80.     {
  81.         $this->quantity 0;
  82.         $this->productId 0;
  83.         $this->purchaseOrder '0';
  84.         $this->purchaseConfirmed 0;
  85.         $this->activeStock 0;
  86.     }
  87.     /**
  88.      * @return int
  89.      */
  90.     public function getId(): int
  91.     {
  92.         return $this->id;
  93.     }
  94.     /**
  95.      * @param int $id
  96.      *
  97.      * @return FutureStock
  98.      */
  99.     public function setId(int $id): FutureStock
  100.     {
  101.         $this->id $id;
  102.         return $this;
  103.     }
  104.     /**
  105.      * @return int
  106.      */
  107.     public function getQuantity(): int
  108.     {
  109.         return $this->quantity;
  110.     }
  111.     /**
  112.      * @param int $quantity
  113.      *
  114.      * @return FutureStock
  115.      */
  116.     public function setQuantity(int $quantity): FutureStock
  117.     {
  118.         $this->quantity $quantity;
  119.         return $this;
  120.     }
  121.     /**
  122.      * @return \DateTime|null
  123.      */
  124.     public function getDateNext(): ?\DateTime
  125.     {
  126.         return $this->dateNext;
  127.     }
  128.     /**
  129.      * @param \DateTime|null $dateNext
  130.      *
  131.      * @return FutureStock
  132.      */
  133.     public function setDateNext(?\DateTime $dateNext): FutureStock
  134.     {
  135.         $this->dateNext $dateNext;
  136.         return $this;
  137.     }
  138.     /**
  139.      * @return int|null
  140.      */
  141.     public function getPurchaseLineId(): ?int
  142.     {
  143.         return $this->purchaseLineId;
  144.     }
  145.     /**
  146.      * @param int|null $purchaseLineId
  147.      *
  148.      * @return FutureStock
  149.      */
  150.     public function setPurchaseLineId(?int $purchaseLineId): FutureStock
  151.     {
  152.         $this->purchaseLineId $purchaseLineId;
  153.         return $this;
  154.     }
  155.     /**
  156.      * @return int
  157.      */
  158.     public function getProductId(): int
  159.     {
  160.         return $this->productId;
  161.     }
  162.     /**
  163.      * @param int $productId
  164.      *
  165.      * @return FutureStock
  166.      */
  167.     public function setProductId(int $productId): FutureStock
  168.     {
  169.         $this->productId $productId;
  170.         return $this;
  171.     }
  172.     /**
  173.      * @return string|null
  174.      */
  175.     public function getPurchaseOrder(): ?string
  176.     {
  177.         return $this->purchaseOrder;
  178.     }
  179.     /**
  180.      * @param string|null $purchaseOrder
  181.      *
  182.      * @return FutureStock
  183.      */
  184.     public function setPurchaseOrder(?string $purchaseOrder): FutureStock
  185.     {
  186.         $this->purchaseOrder $purchaseOrder;
  187.         return $this;
  188.     }
  189.     /**
  190.      * @return bool|null
  191.      */
  192.     public function getPurchaseConfirmed(): ?bool
  193.     {
  194.         return $this->purchaseConfirmed;
  195.     }
  196.     /**
  197.      * @param bool|null $purchaseConfirmed
  198.      *
  199.      * @return FutureStock
  200.      */
  201.     public function setPurchaseConfirmed(?bool $purchaseConfirmed): FutureStock
  202.     {
  203.         $this->purchaseConfirmed $purchaseConfirmed;
  204.         return $this;
  205.     }
  206.     /**
  207.      * @return bool|null
  208.      */
  209.     public function getActiveStock(): ?bool
  210.     {
  211.         return $this->activeStock;
  212.     }
  213.     /**
  214.      * @param bool|null $activeStock
  215.      *
  216.      * @return FutureStock
  217.      */
  218.     public function setActiveStock(?bool $activeStock): FutureStock
  219.     {
  220.         $this->activeStock $activeStock;
  221.         return $this;
  222.     }
  223.     public function getProductAttribute(): ProductAttribute
  224.     {
  225.         return $this->productAttribute;
  226.     }
  227.     public function setProductAttribute(ProductAttribute $productAttribute): FutureStock
  228.     {
  229.         $this->productAttribute $productAttribute;
  230.         return $this;
  231.     }
  232.     public function getProduct(): Product
  233.     {
  234.         return $this->product;
  235.     }
  236.     public function setProduct(Product $product): FutureStock
  237.     {
  238.         $this->product $product;
  239.         return $this;
  240.     }
  241. }