<?php
// src/Acme/UserBundle/Entity/User.php
namespace App\Entity;
use Knp\DoctrineBehaviors\Contract\Entity\SoftDeletableInterface;
use Knp\DoctrineBehaviors\Model\SoftDeletable\SoftDeletableTrait;
use Knp\DoctrineBehaviors\Model\Blameable\BlameableTrait;
use Knp\DoctrineBehaviors\Contract\Entity\BlameableInterface;
use Knp\DoctrineBehaviors\Model\Timestampable\TimestampableTrait;
use Knp\DoctrineBehaviors\Contract\Entity\TimestampableInterface;
use App\Model\LangParamRelationInterface;
use Symfony\Component\Validator\Constraints as Assert;
use Doctrine\ORM\Mapping as ORM;
use Symfony\Bridge\Doctrine\Validator\Constraints\UniqueEntity;
/**
* @Doctrine\ORM\Mapping\Entity
* @Doctrine\ORM\Mapping\Table(name="product_price_variants")
*/
class ProductPriceVariants implements BlameableInterface, TimestampableInterface, SoftDeletableInterface {
use BlameableTrait;
use TimestampableTrait;
use SoftDeletableTrait;
/**
* @var integer
*
* @ORM\Column(name="id", type="integer", nullable=false)
* @ORM\Id
* @ORM\GeneratedValue(strategy="IDENTITY")
*/
private $id;
/**
* @Doctrine\ORM\Mapping\ManyToOne(targetEntity="App\Entity\Product")
* @Doctrine\ORM\Mapping\JoinColumn(name="product_id", referencedColumnName="id")
*/
private $product;
/**
* @Doctrine\ORM\Mapping\ManyToOne(targetEntity="App\Entity\ProductPrice", inversedBy="variants")
* @Doctrine\ORM\Mapping\JoinColumn(name="product_price_id", referencedColumnName="id")
*/
private $productPrice;
/**
* @Doctrine\ORM\Mapping\ManyToOne(targetEntity="App\Entity\ProductParameter")
* @Doctrine\ORM\Mapping\JoinColumn(name="parameter_id", referencedColumnName="id")
*/
private $parameter;
/**
* @Doctrine\ORM\Mapping\ManyToOne(targetEntity="App\Entity\ProductParameterValue", fetch="EAGER")
* @Doctrine\ORM\Mapping\JoinColumn(name="product_parameter_value_id", referencedColumnName="id")
*/
private $parameterValue;
/**
* @Doctrine\ORM\Mapping\ManyToOne(targetEntity="App\Entity\ProductParameterValueGroup", fetch="EAGER")
* @Doctrine\ORM\Mapping\JoinColumn(name="product_parameter_value_group_id", referencedColumnName="id")
*/
private $parameterValueGroup;
/**
* Get id
*
* @return integer
*/
public function getId()
{
return $this->id;
}
public function getProduct(): ?Product
{
return $this->product;
}
public function setProduct(?Product $product): self
{
$this->product = $product;
return $this;
}
public function getProductPrice(): ?ProductPrice
{
return $this->productPrice;
}
public function setProductPrice(?ProductPrice $productPrice): self
{
$this->productPrice = $productPrice;
return $this;
}
public function getParameter(): ?ProductParameter
{
return $this->parameter;
}
public function setParameter(?ProductParameter $parameter): self
{
$this->parameter = $parameter;
return $this;
}
public function getParameterValue(): ?ProductParameterValue
{
return $this->parameterValue;
}
public function setParameterValue(?ProductParameterValue $parameterValue): self
{
$this->parameterValue = $parameterValue;
return $this;
}
public function getParameterValueGroup(): ?ProductParameterValueGroup
{
return $this->parameterValueGroup;
}
public function setParameterValueGroup(?ProductParameterValueGroup $parameterValueGroup): self
{
$this->parameterValueGroup = $parameterValueGroup;
return $this;
}
}