<?php
namespace App\Entity;
use App\Entity\Product\ConfirmedProduct;
use DateTime;
use Doctrine\ORM\Mapping as ORM;
/**
* SimulationLine
*
* @ORM\Table(name="simulation_line")
* @ORM\Entity(repositoryClass="App\Repository\SimulationLineRepository")
* @ORM\HasLifecycleCallbacks()
*/
class SimulationLine
{
/**
* @var int
*
* @ORM\Column(name="id", type="integer")
* @ORM\Id
* @ORM\GeneratedValue(strategy="AUTO")
*/
private $id;
/**
* @var string
*
* @ORM\Column(name="productName", type="string", length=255)
*/
private $productName;
/**
* @var string
*
* @ORM\Column(name="fsa", type="string", length=10, nullable=true)
*/
private $fsa;
/**
* @var string
*
* @ORM\Column(name="code", type="string", length=255, nullable=true)
*/
private $code;
/**
* @var string
*
* @ORM\Column(name="supplierName", type="string", length=255, nullable=true)
*/
private $supplierName;
/**
* @var string
*
* @ORM\Column(name="invoiceUnit", type="string", length=255, nullable=true)
*/
private $invoiceUnit;
/**
* @var float
*
* @ORM\Column(name="customerPrice", type="float", nullable=true)
*/
private $customerPrice;
/**
* @var float
*
* @ORM\Column(name="malysPrice", type="float", nullable=true)
*/
private $malysPrice;
/**
* @var float
*
* @ORM\Column(name="negoPrice", type="float", nullable=true)
*/
private $negoPrice;
/**
* @var bool
*
* @ORM\Column(name="selected", type="boolean", nullable=true)
*/
private $selected;
/**
* @var DateTime
*
* @ORM\Column(name="createdAt", type="datetime")
*/
private $createdAt;
/**
* @var DateTime
*
* @ORM\Column(name="updatedAt", type="datetime")
*/
private $updatedAt;
/**
* @var Simulation
*
* @ORM\ManyToOne(targetEntity="Simulation", inversedBy="lines")
* @ORM\JoinColumn(name="simulation_id", referencedColumnName="id")
*/
protected $simulation;
/**
* @var ConfirmedProduct
*
* @ORM\ManyToOne(targetEntity="App\Entity\Product\ConfirmedProduct")
* @ORM\JoinColumn(name="product_id", referencedColumnName="id", onDelete="SET NULL")
*/
protected $product;
/**
* @var Supplier
*
* @ORM\ManyToOne(targetEntity="Supplier")
* @ORM\JoinColumn(name="supplier_id", referencedColumnName="id")
*/
protected $supplier;
public function __construct()
{
$this->setSelected(true);
}
/**
* @var int
*
* @ORM\Column(name="priority", type="integer", nullable=true)
*/
private $priority;
/**
* @var string
*
* @ORM\Column(name="promotion_type", type="string", length=255, nullable=true)
*/
private $promotionType;
/**
* Get id
*
* @return int
*/
public function getId()
{
return $this->id;
}
/**
* Set productName
*
* @param string $productName
*
* @return SimulationLine
*/
public function setProductName($productName)
{
$this->productName = $productName;
return $this;
}
/**
* Get productName
*
* @return string
*/
public function getProductName()
{
return $this->productName;
}
/**
* Set fsa
*
* @param string $fsa
*
* @return SimulationLine
*/
public function setFsa($fsa)
{
$this->fsa = $fsa;
return $this;
}
/**
* Get fsa
*
* @return string
*/
public function getFsa()
{
return $this->fsa;
}
/**
* Set code
*
* @param string $code
*
* @return SimulationLine
*/
public function setCode($code)
{
$this->code = $code;
return $this;
}
/**
* Get code
*
* @return string
*/
public function getCode()
{
return $this->code;
}
/**
* Set supplierName
*
* @param string $supplierName
*
* @return SimulationLine
*/
public function setSupplierName($supplierName)
{
$this->supplierName = $supplierName;
return $this;
}
/**
* Get supplierName
*
* @return string
*/
public function getSupplierName()
{
return $this->supplierName;
}
/**
* Set customerPrice
*
* @param float $customerPrice
*
* @return SimulationLine
*/
public function setCustomerPrice($customerPrice)
{
$this->customerPrice = $customerPrice;
return $this;
}
/**
* Get customerPrice
*
* @return float
*/
public function getCustomerPrice()
{
return $this->customerPrice;
}
/**
* Set malysPrice
*
* @param float $malysPrice
*
* @return SimulationLine
*/
public function setMalysPrice($malysPrice)
{
$this->malysPrice = $malysPrice;
return $this;
}
/**
* Get malysPrice
*
* @return float
*/
public function getMalysPrice()
{
return $this->malysPrice;
}
/**
* Set negoPrice
*
* @param float $negoPrice
*
* @return SimulationLine
*/
public function setNegoPrice($negoPrice)
{
$this->negoPrice = $negoPrice;
return $this;
}
/**
* Get negoPrice
*
* @return float
*/
public function getNegoPrice()
{
return $this->negoPrice;
}
/**
* Set selected
*
* @param boolean $selected
*
* @return SimulationLine
*/
public function setSelected($selected)
{
$this->selected = $selected;
return $this;
}
/**
* Get selected
*
* @return bool
*/
public function getSelected()
{
return $this->selected;
}
/**
* @ORM\PrePersist
*/
public function setCreatedAt()
{
$this->createdAt = new DateTime();
$this->updatedAt = new DateTime();
return $this;
}
/**
* Get createdAt
*
* @return DateTime
*/
public function getCreatedAt()
{
return $this->createdAt;
}
/**
* Set updatedAt
* @ORM\PreUpdate
*/
public function setUpdatedAt()
{
$this->updatedAt = new DateTime();
return $this;
}
/**
* Get updatedAt
*
* @return DateTime
*/
public function getUpdatedAt()
{
return $this->updatedAt;
}
/**
* @return Simulation
*/
public function getSimulation()
{
return $this->simulation;
}
/**
* @param Simulation $simulation
*/
public function setSimulation($simulation)
{
$this->simulation = $simulation;
}
/**
* @return ConfirmedProduct
*/
public function getProduct()
{
return $this->product;
}
/**
* @param ConfirmedProduct $product
*/
public function setProduct($product)
{
$this->product = $product;
}
/**
* @return int
*/
public function getPriority()
{
return $this->priority;
}
/**
* @param int $priority
*/
public function setPriority($priority)
{
$this->priority = $priority;
}
/**
* @return Supplier
*/
public function getSupplier()
{
return $this->supplier;
}
/**
* @param Supplier $supplier
*/
public function setSupplier($supplier)
{
$this->supplier = $supplier;
}
/**
* @return string
*/
public function getInvoiceUnit()
{
return $this->invoiceUnit;
}
/**
* @param string $invoiceUnit
*/
public function setInvoiceUnit($invoiceUnit)
{
$this->invoiceUnit = $invoiceUnit;
}
/**
* @return string
*/
public function getPromotionType()
{
return $this->promotionType;
}
/**
* @param string $promotionType
*/
public function setPromotionType($promotionType)
{
$this->promotionType = $promotionType;
}
}