src/Entity/SecFuncion.php line 11

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use App\Repository\SecFuncionRepository;
  4. use Doctrine\Common\Collections\ArrayCollection;
  5. use Doctrine\Common\Collections\Collection;
  6. use Doctrine\ORM\Mapping as ORM;
  7. #[ORM\Entity(repositoryClassSecFuncionRepository::class)]
  8. class SecFuncion
  9. {
  10.     #[ORM\Id]
  11.     #[ORM\GeneratedValue]
  12.     #[ORM\Column]
  13.     private ?int $id null;
  14.     #[ORM\Column(length100)]
  15.     private ?string $nombre null;
  16.     #[ORM\Column(length100nullabletrue)]
  17.     private ?string $icono null;
  18.     #[ORM\Column(length100nullabletrue)]
  19.     private ?string $class null;
  20.     #[ORM\Column]
  21.     private ?int $orden null;
  22.     #[ORM\Column(length100)]
  23.     private ?string $endpoint null;
  24.     #[ORM\ManyToOne(inversedBy'secFuncion')]
  25.     private ?SecModulo $modulo null;
  26.     #[ORM\OneToMany(mappedBy'funcion'targetEntitySecAccion::class)]
  27.     private Collection $secAccion;
  28.     #[ORM\Column]
  29.     private ?bool $subFuncion null;
  30.     #[ORM\Column(nullabletrue)]
  31.     private ?int $funcionPadre null;
  32.     #[ORM\Column(length300nullabletrue)]
  33.     private ?string $repository null;
  34.     #[ORM\Column(nullabletrue)]
  35.     private ?int $tipo null;
  36.    
  37.     public function __construct()
  38.     {
  39.         $this->modulo = new ArrayCollection();
  40.         $this->secAccion = new ArrayCollection();
  41.     }
  42.     public function getId(): ?int
  43.     {
  44.         return $this->id;
  45.     }
  46.     public function getNombre(): ?string
  47.     {
  48.         return $this->nombre;
  49.     }
  50.     public function setNombre(string $nombre): static
  51.     {
  52.         $this->nombre $nombre;
  53.         return $this;
  54.     }
  55.     public function getIcono(): ?string
  56.     {
  57.         return $this->icono;
  58.     }
  59.     public function setIcono(?string $icono): static
  60.     {
  61.         $this->icono $icono;
  62.         return $this;
  63.     }
  64.     public function getClass(): ?string
  65.     {
  66.         return $this->class;
  67.     }
  68.     public function setClass(?string $class): static
  69.     {
  70.         $this->class $class;
  71.         return $this;
  72.     }
  73.     public function getOrden(): ?int
  74.     {
  75.         return $this->orden;
  76.     }
  77.     public function setOrden(int $orden): static
  78.     {
  79.         $this->orden $orden;
  80.         return $this;
  81.     }
  82.     public function getEndpoint(): ?string
  83.     {
  84.         return $this->endpoint;
  85.     }
  86.     public function setEndpoint(string $endpoint): static
  87.     {
  88.         $this->endpoint $endpoint;
  89.         return $this;
  90.     }
  91.     public function getModulo(): ?SecModulo
  92.     {
  93.         return $this->modulo;
  94.     }
  95.     public function setModulo(?SecModulo $modulo): static
  96.     {
  97.         $this->modulo $modulo;
  98.         return $this;
  99.     }
  100.     /**
  101.      * @return Collection<int, SecAccion>
  102.      */
  103.     public function getSecAccion(): Collection
  104.     {
  105.         return $this->secAccion;
  106.     }
  107.     public function addSecAccion(SecAccion $secAccion): static
  108.     {
  109.         if (!$this->secAccion->contains($secAccion)) {
  110.             $this->secAccion->add($secAccion);
  111.             $secAccion->setFuncion($this);
  112.         }
  113.         return $this;
  114.     }
  115.     public function removeSecAccion(SecAccion $secAccion): static
  116.     {
  117.         if ($this->secAccion->removeElement($secAccion)) {
  118.             // set the owning side to null (unless already changed)
  119.             if ($secAccion->getFuncion() === $this) {
  120.                 $secAccion->setFuncion(null);
  121.             }
  122.         }
  123.         return $this;
  124.     }
  125.     public function isSubFuncion(): ?bool
  126.     {
  127.         return $this->subFuncion;
  128.     }
  129.     public function setSubFuncion(bool $subFuncion): static
  130.     {
  131.         $this->subFuncion $subFuncion;
  132.         return $this;
  133.     }
  134.     public function getFuncionPadre(): ?int
  135.     {
  136.         return $this->funcionPadre;
  137.     }
  138.     public function setFuncionPadre(?int $funcionPadre): static
  139.     {
  140.         $this->funcionPadre $funcionPadre;
  141.         return $this;
  142.     }
  143.     public function getRepository(): ?string
  144.     {
  145.         return $this->repository;
  146.     }
  147.     public function setRepository(?string $repository): static
  148.     {
  149.         $this->repository $repository;
  150.         return $this;
  151.     }
  152.     public function getTipo(): ?int
  153.     {
  154.         return $this->tipo;
  155.     }
  156.     public function setTipo(?int $tipo): static
  157.     {
  158.         $this->tipo $tipo;
  159.         return $this;
  160.     }
  161.   
  162.   
  163.  
  164. }