<?php
namespace App\Admin\Entity;
use Doctrine\ORM\Mapping as ORM;
/**
* StdOptionsPermissions
*/
#[ORM\Table(name: 'std_options_permissions')]
#[ORM\Index(name: 'fk_std_options_permissions_std_users', columns: ['created_by'])]
#[ORM\Index(name: 'fk_std_options_permissions_std_options', columns: ['option_id'])]
#[ORM\Index(name: 'fk_std_options_permissions_std_users_0', columns: ['updated_by'])]
#[ORM\Entity]
class StdOptionsPermissions
{
/**
* @var int
*/
#[ORM\Column(name: 'id', type: 'integer', nullable: false, options: ['unsigned' => true, 'comment' => 'Unique identifier'])]
#[ORM\Id]
#[ORM\GeneratedValue(strategy: 'IDENTITY')]
private $id;
/**
* @var string|null
*/
#[ORM\Column(name: 'machine_name', type: 'string', length: 50, nullable: true, options: ['comment' => 'Code used in the programming to identify the option permission'])]
private $machineName;
/**
* @var string|null
*/
#[ORM\Column(name: 'name', type: 'string', length: 50, nullable: true, options: ['comment' => 'Name of the Feature'])]
private $name;
#[ORM\Column(type: 'string', length: 255)]
private $description;
/**
* @var int|null
*/
#[ORM\Column(name: 'bits', type: 'integer', nullable: true, options: ['unsigned' => true, 'comment' => 'Value of the Feature - it has to be a power of 2 and unique for the option'])]
private $bits;
/**
* @var int|null
*/
#[ORM\Column(name: 'order_value', type: 'integer', nullable: true, options: ['comment' => 'Order of the Feature'])]
private $orderValue = '0';
/**
* @var \DateTime
*/
#[ORM\Column(name: 'created_date', type: 'datetime', nullable: false, options: ['default' => 'CURRENT_TIMESTAMP', 'comment' => 'Date and time of the record creation'])]
private $createdDate = 'CURRENT_TIMESTAMP';
/**
* @var \DateTime
*/
#[ORM\Column(name: 'updated_date', type: 'datetime', nullable: false, options: ['default' => 'CURRENT_TIMESTAMP', 'comment' => 'Date and time the record was last updated'])]
private $updatedDate = 'CURRENT_TIMESTAMP';
/**
* @var \StdOptions
*/
#[ORM\ManyToOne(targetEntity: StdOptions::class, inversedBy: 'permissions')]
#[ORM\JoinColumn(name: 'option_id', referencedColumnName: 'id', nullable: false)]
private $option = null;
/**
* @var \StdUsers
*/
#[ORM\JoinColumn(name: 'created_by', referencedColumnName: 'id')]
#[ORM\ManyToOne(targetEntity: 'StdUsers')]
private $createdBy;
/**
* @var \StdUsers
*/
#[ORM\JoinColumn(name: 'updated_by', referencedColumnName: 'id')]
#[ORM\ManyToOne(targetEntity: 'StdUsers')]
private $updatedBy;
public function getId(): ?int
{
return $this->id;
}
public function getMachineName(): ?string
{
return $this->machineName;
}
public function setMachineName(?string $machineName): self
{
$this->machineName = $machineName;
return $this;
}
public function getName(): ?string
{
return $this->name;
}
public function setName(?string $name): self
{
$this->name = $name;
return $this;
}
public function getBits(): ?int
{
return $this->bits;
}
public function setBits(?int $value): self
{
$this->bits = $value;
return $this;
}
public function getOrderValue(): ?int
{
return $this->orderValue;
}
public function setOrderValue(?int $orderValue): self
{
$this->orderValue = $orderValue;
return $this;
}
public function getCreatedDate(): ?\DateTimeInterface
{
return $this->createdDate;
}
public function setCreatedDate(\DateTimeInterface $createdDate): self
{
$this->createdDate = $createdDate;
return $this;
}
public function getUpdatedDate(): ?\DateTimeInterface
{
return $this->updatedDate;
}
public function setUpdatedDate(\DateTimeInterface $updatedDate): self
{
$this->updatedDate = $updatedDate;
return $this;
}
public function getOption(): ?StdOptions
{
return $this->option;
}
public function setOption(?StdOptions $option): self
{
$this->option = $option;
return $this;
}
public function getCreatedBy(): ?StdUsers
{
return $this->createdBy;
}
public function setCreatedBy(?StdUsers $createdBy): self
{
$this->createdBy = $createdBy;
return $this;
}
public function getUpdatedBy(): ?StdUsers
{
return $this->updatedBy;
}
public function setUpdatedBy(?StdUsers $updatedBy): self
{
$this->updatedBy = $updatedBy;
return $this;
}
/**
* @return mixed
*/
public function getDescription()
{
return $this->description;
}
/**
* @param mixed $description
*/
public function setDescription($description): void
{
$this->description = $description;
}
}