src/Entity/Container.php line 11

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use App\Repository\ContainerRepository;
  4. use Doctrine\Common\Collections\ArrayCollection;
  5. use Doctrine\Common\Collections\Collection;
  6. use Doctrine\ORM\Mapping as ORM;
  7. #[ORM\Entity(repositoryClassContainerRepository::class)]
  8. class Container extends BaseEntity
  9. {
  10.     #[ORM\Id]
  11.     #[ORM\GeneratedValue]
  12.     #[ORM\Column(type'integer')]
  13.     private $id;
  14.     #[ORM\Column(type'string'length255)]
  15.     private $containerNumber;
  16.     #[ORM\Column(type'decimal'precision19scale4)]
  17.     private $totalPrice;
  18.     #[ORM\Column(type'decimal'precision19scale4)]
  19.     private $totalProductUnit;
  20.     #[ORM\Column(type'decimal'precision19scale4)]
  21.     private $totalNavlun;
  22.     #[ORM\Column(type'decimal'precision19scale4)]
  23.     private $unitNavlunPrice;
  24.     #[ORM\ManyToOne(targetEntityNewStockTransfer::class, inversedBy'containers')]
  25.     private $newStockTransfer;
  26.     #[ORM\OneToMany(mappedBy'container'targetEntityNewTransferProducts::class)]
  27.     private $newTransferProducts;
  28.     #[ORM\Column(type'boolean'nullabletrue)]
  29.     private $isTransfered;
  30.     #[ORM\Column(type'float'nullabletrue)]
  31.     private $onaylananQuantity;
  32.     public function __construct()
  33.     {
  34.         $this->newTransferProducts = new ArrayCollection();
  35.     }
  36.     public function getId(): ?int
  37.     {
  38.         return $this->id;
  39.     }
  40.     public function getContainerNumber(): ?string
  41.     {
  42.         return $this->containerNumber;
  43.     }
  44.     public function setContainerNumber(string $containerNumber): self
  45.     {
  46.         $this->containerNumber $containerNumber;
  47.         return $this;
  48.     }
  49.     public function getTotalPrice(): ?float
  50.     {
  51.         return $this->totalPrice;
  52.     }
  53.     public function setTotalPrice(float $totalPrice): self
  54.     {
  55.         $this->totalPrice $totalPrice;
  56.         return $this;
  57.     }
  58.     public function getTotalProductUnit(): ?float
  59.     {
  60.         return $this->totalProductUnit;
  61.     }
  62.     public function setTotalProductUnit(float $totalProductUnit): self
  63.     {
  64.         $this->totalProductUnit $totalProductUnit;
  65.         return $this;
  66.     }
  67.     public function getTotalNavlun(): ?float
  68.     {
  69.         return $this->totalNavlun;
  70.     }
  71.     public function setTotalNavlun(float $totalNavlun): self
  72.     {
  73.         $this->totalNavlun $totalNavlun;
  74.         return $this;
  75.     }
  76.     public function getUnitNavlunPrice(): ?float
  77.     {
  78.         return $this->unitNavlunPrice;
  79.     }
  80.     public function setUnitNavlunPrice(float $unitNavlunPrice): self
  81.     {
  82.         $this->unitNavlunPrice $unitNavlunPrice;
  83.         return $this;
  84.     }
  85.     public function getNewStockTransfer(): ?NewStockTransfer
  86.     {
  87.         return $this->newStockTransfer;
  88.     }
  89.     public function setNewStockTransfer(?NewStockTransfer $newStockTransfer): self
  90.     {
  91.         $this->newStockTransfer $newStockTransfer;
  92.         return $this;
  93.     }
  94.     /**
  95.      * @return Collection<int, NewTransferProducts>
  96.      */
  97.     public function getNewTransferProducts(): Collection
  98.     {
  99.         return $this->newTransferProducts;
  100.     }
  101.     public function addNewTransferProduct(NewTransferProducts $newTransferProduct): self
  102.     {
  103.         if (!$this->newTransferProducts->contains($newTransferProduct)) {
  104.             $this->newTransferProducts[] = $newTransferProduct;
  105.             $newTransferProduct->setContainer($this);
  106.         }
  107.         return $this;
  108.     }
  109.     public function removeNewTransferProduct(NewTransferProducts $newTransferProduct): self
  110.     {
  111.         if ($this->newTransferProducts->removeElement($newTransferProduct)) {
  112.             // set the owning side to null (unless already changed)
  113.             if ($newTransferProduct->getContainer() === $this) {
  114.                 $newTransferProduct->setContainer(null);
  115.             }
  116.         }
  117.         return $this;
  118.     }
  119.     /**
  120.      * @return bool
  121.      */
  122.     public function isTransfered(): bool
  123.     {
  124.         return $this->isTransfered;
  125.     }
  126.     /**
  127.      * @param bool $isTransfered
  128.      */
  129.     public function setIsTransfered(bool $isTransfered): void
  130.     {
  131.         $this->isTransfered $isTransfered;
  132.     }
  133.     /**
  134.      * @return mixed
  135.      */
  136.     public function getOnaylananQuantity()
  137.     {
  138.         return $this->onaylananQuantity;
  139.     }
  140.     /**
  141.      * @param mixed $onaylananQuantity
  142.      */
  143.     public function setOnaylananQuantity($onaylananQuantity): void
  144.     {
  145.         $this->onaylananQuantity $onaylananQuantity;
  146.     }
  147. }