src/Entity/SpecialDiscount.php line 9
<?php
namespace App\Entity;
use App\Repository\SpecialDiscountRepository;
use Doctrine\ORM\Mapping as ORM;
#[ORM\Entity(repositoryClass: SpecialDiscountRepository::class)]
class SpecialDiscount
{
#[ORM\Id]
#[ORM\GeneratedValue]
#[ORM\Column]
private ?int $id = null;
#[ORM\ManyToOne(targetEntity: Products::class, inversedBy: 'specialDiscount', fetch: 'EAGER')]
private $product;
#[ORM\Column(name: 'dateStart', type: 'date', nullable: true)]
private ?\DateTime $dateStart;
#[ORM\Column(name: 'dateEnd', type: 'date', nullable: true)]
private ?\DateTime $dateEnd;
#[ORM\Column(name: 'pourcentRebate', type: 'integer')]
private ?int $pourcentRebate;
#[ORM\Column(name: 'image', type: 'text', nullable: true)]
private ?string $image;
public function getId(): ?int
{
return $this->id;
}
/**
* @return mixed
*/
public function getProduct()
{
return $this->product;
}
/**
* @param mixed $product
*/
public function setProduct($product): void
{
$this->product = $product;
}
/**
* @return \DateTime|null
*/
public function getDateStart(): ?\DateTime
{
return $this->dateStart;
}
/**
* @param \DateTime|null $dateStart
*/
public function setDateStart(?\DateTime $dateStart): void
{
$this->dateStart = $dateStart;
}
/**
* @return \DateTime|null
*/
public function getDateEnd(): ?\DateTime
{
return $this->dateEnd;
}
/**
* @param \DateTime|null $dateEnd
*/
public function setDateEnd(?\DateTime $dateEnd): void
{
$this->dateEnd = $dateEnd;
}
/**
* @return int|null
*/
public function getPourcentRebate(): ?int
{
return $this->pourcentRebate;
}
/**
* @param int|null $pourcentRebate
*/
public function setPourcentRebate(?int $pourcentRebate): void
{
$this->pourcentRebate = $pourcentRebate;
}
/**
* @return string|null
*/
public function getImage(): ?string
{
return $this->image;
}
/**
* @param string|null $image
*/
public function setImage(?string $image): void
{
$this->image = $image;
}
}