src/Core/Entity/SugerenciaCategoria.php line 12

Open in your IDE?
  1. <?php
  2. namespace App\Core\Entity;
  3. use App\Core\Entity\User;
  4. use App\Core\Repository\SugerenciaCategoriaRepository;
  5. use Doctrine\ORM\Mapping as ORM;
  6. /**
  7. * @ORM\Entity(repositoryClass=SugerenciaCategoriaRepository::class)
  8. */
  9. class SugerenciaCategoria
  10. {
  11. /**
  12. * @ORM\Id()
  13. * @ORM\GeneratedValue()
  14. * @ORM\Column(type="integer")
  15. */
  16. private $id;
  17. /**
  18. * @ORM\Column(type="string", length=100)
  19. */
  20. private $nombre;
  21. /**
  22. * @ORM\Column(type="datetime")
  23. */
  24. private $fecha;
  25. /**
  26. * @ORM\ManyToOne(targetEntity=User::class)
  27. * @ORM\JoinColumn(nullable=false)
  28. */
  29. private $usuario;
  30. public function getId(): ?int
  31. {
  32. return $this->id;
  33. }
  34. public function getNombre(): ?string
  35. {
  36. return $this->nombre;
  37. }
  38. public function setNombre(string $nombre): self
  39. {
  40. $this->nombre = $nombre;
  41. return $this;
  42. }
  43. public function getFecha(): ?\DateTimeInterface
  44. {
  45. return $this->fecha;
  46. }
  47. public function setFecha(\DateTimeInterface $fecha): self
  48. {
  49. $this->fecha = $fecha;
  50. return $this;
  51. }
  52. public function getUsuario(): ?User
  53. {
  54. return $this->usuario;
  55. }
  56. public function setUsuario(?User $usuario): self
  57. {
  58. $this->usuario = $usuario;
  59. return $this;
  60. }
  61. }