src/Entity/SaasConfiguration.php line 14
<?phpnamespace App\Entity;use App\Repository\SaasConfigurationRepository;use Doctrine\Common\Collections\ArrayCollection;use Doctrine\Common\Collections\Collection;use Doctrine\ORM\Mapping as ORM;use Symfony\Component\Validator\Constraints\GreaterThanOrEqual;use Symfony\Component\Validator\Constraints\NotNull;use Symfony\Component\Validator\Constraints\Valid;#[ORM\Entity(repositoryClass: SaasConfigurationRepository::class)]class SaasConfiguration{#[ORM\Id]#[ORM\GeneratedValue]#[ORM\Column]private ?int $id = null;#[ORM\OneToOne(inversedBy: 'limits', cascade: ['persist', 'remove'])]#[ORM\JoinColumn(nullable: false)]private ?SriInfo $company = null;#[ORM\Column(nullable: true)]private ?bool $showTransporter = null;#[ORM\Column(nullable: true)]#[NotNull]#[GreaterThanOrEqual(0)]private ?int $sucursalLimit = null;#[ORM\OneToMany(mappedBy: 'saasConfiguration', targetEntity: SaasDocAllowed::class, cascade: ['persist'], orphanRemoval: true)]#[Valid(traverse: true)]private Collection $docAlloweds;public function __construct(){$this->docAlloweds = new ArrayCollection();}public function getId(): ?int{return $this->id;}public function getCompany(): ?SriInfo{return $this->company;}public function setCompany(SriInfo $company): self{$this->company = $company;return $this;}public function isShowTransporter(): ?bool{return $this->showTransporter;}public function setShowTransporter(?bool $showTransporter): self{$this->showTransporter = $showTransporter;return $this;}public function getSucursalLimit(): ?int{return $this->sucursalLimit;}public function setSucursalLimit(?int $sucursalLimit): self{$this->sucursalLimit = $sucursalLimit;return $this;}/*** @return Collection<int, SaasDocAllowed>*/public function getDocAlloweds(): Collection{return $this->docAlloweds;}public function addDocAllowed(SaasDocAllowed $docAllowed): self{if (!$this->docAlloweds->contains($docAllowed)) {$this->docAlloweds->add($docAllowed);$docAllowed->setSaasConfiguration($this);}return $this;}public function removeDocAllowed(SaasDocAllowed $docAllowed): self{if ($this->docAlloweds->removeElement($docAllowed)) {// set the owning side to null (unless already changed)if ($docAllowed->getSaasConfiguration() === $this) {$docAllowed->setSaasConfiguration(null);}}return $this;}}