src/Entity/ComGerencia.php line 12

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use App\Repository\ComGerenciaRepository;
  4. use Doctrine\Common\Collections\ArrayCollection;
  5. use Doctrine\Common\Collections\Collection;
  6. use Doctrine\DBAL\Types\Types;
  7. use Doctrine\ORM\Mapping as ORM;
  8. #[ORM\Entity(repositoryClassComGerenciaRepository::class)]
  9. class ComGerencia
  10. {
  11.     #[ORM\Id]
  12.     #[ORM\GeneratedValue]
  13.     #[ORM\Column]
  14.     private ?int $id null;
  15.     #[ORM\ManyToMany(targetEntityTerPersona::class, inversedBy'comGerencias')]
  16.     private Collection $colaborador;
  17.     #[ORM\Column(typeTypes::DATETIME_MUTABLE)]
  18.     private ?\DateTimeInterface $createAt null;
  19.     #[ORM\Column(length255)]
  20.     private ?string $createUser null;
  21.     #[ORM\Column(typeTypes::DATETIME_MUTABLE)]
  22.     private ?\DateTimeInterface $updateAt null;
  23.     #[ORM\Column(length255)]
  24.     private ?string $updateUser null;
  25.     #[ORM\ManyToOne(inversedBy'comGerencia')]
  26.     private ?ComMapaComunicaciones $comMapaComunicaciones null;
  27.     public function __construct()
  28.     {
  29.         $this->colaborador = new ArrayCollection();
  30.     }
  31.     public function getId(): ?int
  32.     {
  33.         return $this->id;
  34.     }
  35.     /**
  36.      * @return Collection<int, TerPersona>
  37.      */
  38.     public function getColaborador(): Collection
  39.     {
  40.         return $this->colaborador;
  41.     }
  42.     public function addColaborador(TerPersona $colaborador): static
  43.     {
  44.         if (!$this->colaborador->contains($colaborador)) {
  45.             $this->colaborador->add($colaborador);
  46.         }
  47.         return $this;
  48.     }
  49.     public function removeColaborador(TerPersona $colaborador): static
  50.     {
  51.         $this->colaborador->removeElement($colaborador);
  52.         return $this;
  53.     }
  54.     public function getCreateAt(): ?\DateTimeInterface
  55.     {
  56.         return $this->createAt;
  57.     }
  58.     public function setCreateAt(\DateTimeInterface $createAt): static
  59.     {
  60.         $this->createAt $createAt;
  61.         return $this;
  62.     }
  63.     public function getCreateUser(): ?string
  64.     {
  65.         return $this->createUser;
  66.     }
  67.     public function setCreateUser(string $createUser): static
  68.     {
  69.         $this->createUser $createUser;
  70.         return $this;
  71.     }
  72.     public function getUpdateAt(): ?\DateTimeInterface
  73.     {
  74.         return $this->updateAt;
  75.     }
  76.     public function setUpdateAt(\DateTimeInterface $updateAt): static
  77.     {
  78.         $this->updateAt $updateAt;
  79.         return $this;
  80.     }
  81.     public function getUpdateUser(): ?string
  82.     {
  83.         return $this->updateUser;
  84.     }
  85.     public function setUpdateUser(string $updateUser): static
  86.     {
  87.         $this->updateUser $updateUser;
  88.         return $this;
  89.     }
  90.     public function getComMapaComunicaciones(): ?ComMapaComunicaciones
  91.     {
  92.         return $this->comMapaComunicaciones;
  93.     }
  94.     public function setComMapaComunicaciones(?ComMapaComunicaciones $comMapaComunicaciones): static
  95.     {
  96.         $this->comMapaComunicaciones $comMapaComunicaciones;
  97.         return $this;
  98.     }
  99. }