src/Entity/Project.php line 10

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use App\Repository\ProjectRepository;
  4. use Doctrine\DBAL\Types\Types;
  5. use Doctrine\ORM\Mapping as ORM;
  6. #[ORM\Entity(repositoryClass: ProjectRepository::class)]
  7. class Project
  8. {
  9.     #[ORM\Id]
  10.     #[ORM\GeneratedValue]
  11.     #[ORM\Column(type: 'integer', nullable: false)]
  12.     private $id;
  13.     #[ORM\Column(type: 'integer', nullable: false)]
  14.     private $id_user;
  15.     #[ORM\Column(type: 'integer', nullable: false)]
  16.     private $id_mun;
  17.     #[ORM\Column(type: 'string', length: 100, nullable: true)]
  18.     private $name;
  19.     #[ORM\Column(type: Types::TEXT, nullable: true)]
  20.     private $description;
  21.     #[ORM\Column(type: 'integer', nullable: false)]
  22.     private $date;
  23.     // #[ORM\OneToOne(mappedBy: 'project', cascade: ['persist', 'remove'])]
  24.     // private ?ProjectData $projectData = null;
  25.     #[ORM\OneToOne(mappedBy: 'project')]
  26.     private ?Projectdata $projectdata = null;
  27.     // #[ORM\ManyToOne(inversedBy: 'projects')]
  28.     // private ?Municipio $adminunitname = null;
  29.     public function getId(): ?int
  30.     {
  31.         return $this->id;
  32.     }
  33.     public function getIdUser(): ?int
  34.     {
  35.         return $this->id_user;
  36.     }
  37.     public function setIdUser(int $id_user): self
  38.     {
  39.         $this->id_user = $id_user;
  40.         return $this;
  41.     }
  42.     public function getIdMun(): ?int
  43.     {
  44.         return $this->id_mun;
  45.     }
  46.     public function setIdMun(?int $id_mun): self
  47.     {
  48.         $this->id_mun = $id_mun;
  49.         return $this;
  50.     }
  51.     public function getName(): ?string
  52.     {
  53.         return $this->name;
  54.     }
  55.     public function setName(?string $name): self
  56.     {
  57.         $this->name = $name;
  58.         return $this;
  59.     }
  60.     public function getDescription(): ?string
  61.     {
  62.         return $this->description;
  63.     }
  64.     public function setDescription(?string $description): self
  65.     {
  66.         $this->description = $description;
  67.         return $this;
  68.     }
  69.     public function getDate(): ?int
  70.     {
  71.         return $this->date;
  72.     }
  73.     public function setDate(int $date): self
  74.     {
  75.         $this->date = $date;
  76.         return $this;
  77.     }
  78.     // public function getAdminunitname(): ?Municipio
  79.     // {
  80.     //     return $this->adminunitname;
  81.     // }
  82.     // public function setAdminunitname(?Municipio $adminunitname): static
  83.     // {
  84.     //     $this->adminunitname = $adminunitname;
  85.     //     return $this;
  86.     // }
  87.     public function getProjectdata(): ?Projectdata
  88.     {
  89.         return $this->projectdata;
  90.     }
  91.     public function setProjectdata(?Projectdata $projectdata): static
  92.     {
  93.         $this->projectdata = $projectdata;
  94.         return $this;
  95.     }
  96. }