<?php
namespace App\Entity\BaseSite\Plan;
use App\Entity\BaseEntity;
use App\Entity\Shop\Shop\Shop;
use App\Repository\BaseSite\Plan\AddOnRepository;
use Doctrine\DBAL\Types\Types;
use Doctrine\ORM\Mapping as ORM;
use Symfony\Bridge\Doctrine\IdGenerator\UuidGenerator;
#[ORM\Entity(repositoryClass: AddOnRepository::class)]
class AddOn extends BaseEntity
{
#[ORM\Id]
#[ORM\Column(type: 'guid', unique: true)]
#[ORM\GeneratedValue(strategy: 'CUSTOM')]
#[ORM\CustomIdGenerator(class: UuidGenerator::class)]
private ?string $id;
#[ORM\ManyToOne(inversedBy: 'addOns')]
#[ORM\JoinColumn(nullable: false)]
private ?Shop $shop = null;
#[ORM\ManyToOne(inversedBy: 'addOns')]
#[ORM\JoinColumn(nullable: false)]
private ?Feature $feature = null;
#[ORM\Column(type: Types::BIGINT)]
private ?string $value = null;
#[ORM\Column(type: Types::BIGINT)]
private ?string $priceOfThisUnit = null;
#[ORM\ManyToOne(inversedBy: 'addOns')]
#[ORM\JoinColumn(nullable: false)]
private ?Plan $plan = null;
public function getId(): ?string
{
return $this->id;
}
public function getShop(): ?Shop
{
return $this->shop;
}
public function setShop(?Shop $shop): static
{
$this->shop = $shop;
return $this;
}
public function getFeature(): ?Feature
{
return $this->feature;
}
public function setFeature(?Feature $feature): static
{
$this->feature = $feature;
return $this;
}
public function getValue(): ?string
{
return $this->value;
}
public function setValue(string $value): static
{
$this->value = $value;
return $this;
}
public function getPriceOfThisUnit(): ?string
{
return $this->priceOfThisUnit;
}
public function setPriceOfThisUnit(string $priceOfThisUnit): static
{
$this->priceOfThisUnit = $priceOfThisUnit;
return $this;
}
public function getPlan(): ?Plan
{
return $this->plan;
}
public function setPlan(?Plan $plan): static
{
$this->plan = $plan;
return $this;
}
}