src/Entity/Enlace.php line 13

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use Doctrine\DBAL\Types\Types;
  4. use Doctrine\ORM\Mapping as ORM;
  5. use Gedmo\Mapping\Annotation as Gedmo;
  6. /**
  7. * @ORM\Entity
  8. * @ORM\Table(name="enlace")
  9. */
  10. class Enlace
  11. {
  12. /**
  13. * @ORM\Id
  14. * @ORM\Column(type="integer")
  15. * @ORM\GeneratedValue(strategy="AUTO")
  16. */
  17. private $id;
  18. /**
  19. * @ORM\Column(type="string", nullable=true)
  20. */
  21. private $descripcion;
  22. /**
  23. * @ORM\Column(type="string", nullable=true)
  24. */
  25. private $link;
  26. /**
  27. * @ORM\Column(type="string", nullable=true, name="red_social")
  28. */
  29. private $redSocial;
  30. /**
  31. * @ORM\Column(type="datetime", nullable=true, name="deleted_at")
  32. */
  33. private $deletedAt;
  34. /**
  35. * @ORM\Column(type="datetime", nullable=false, name="updated_at", options={"default":"2024-01-01 00:00:00"})
  36. * @Gedmo\Timestampable(on="update")
  37. */
  38. private $updatedAt;
  39. /**
  40. * @ORM\Column(type="datetime", nullable=false, name="created_at", options={"default":"2024-01-01 00:00:00"})
  41. * @Gedmo\Timestampable(on="create")
  42. */
  43. private $createdAt;
  44. /**
  45. * @ORM\ManyToOne(targetEntity=\App\Entity\EntidadColaboradora::class, inversedBy="enlace")
  46. * @ORM\JoinColumn(name="entidad_colaboradora_id", referencedColumnName="id", nullable=false)
  47. */
  48. private $entidadColaboradora;
  49. /**
  50. * @ORM\ManyToOne(targetEntity=\App\Entity\Noticia::class, inversedBy="enlaces")
  51. * @ORM\JoinColumn(name="noticia_id", referencedColumnName="id")
  52. */
  53. private $noticia;
  54. public function getId(): ?int
  55. {
  56. return $this->id;
  57. }
  58. public function setId($id)
  59. {
  60. $this->id = $id;
  61. return $this;
  62. }
  63. public function getDescripcion(): ?string
  64. {
  65. return $this->descripcion;
  66. }
  67. public function setDescripcion(?string $descripcion): static
  68. {
  69. $this->descripcion = $descripcion;
  70. return $this;
  71. }
  72. public function getLink(): ?string
  73. {
  74. return $this->link;
  75. }
  76. public function setLink(?string $link): static
  77. {
  78. $this->link = $link;
  79. return $this;
  80. }
  81. public function getRedSocial(): ?string
  82. {
  83. return $this->redSocial;
  84. }
  85. public function setRedSocial(?string $redSocial): static
  86. {
  87. $this->redSocial = $redSocial;
  88. return $this;
  89. }
  90. public function getDeletedAt(): ?\DateTimeInterface
  91. {
  92. return $this->deletedAt;
  93. }
  94. public function setDeletedAt(?\DateTimeInterface $deletedAt): static
  95. {
  96. $this->deletedAt = $deletedAt;
  97. return $this;
  98. }
  99. public function getUpdatedAt(): ?\DateTimeInterface
  100. {
  101. return $this->updatedAt;
  102. }
  103. public function setUpdatedAt(\DateTimeInterface $updatedAt): static
  104. {
  105. $this->updatedAt = $updatedAt;
  106. return $this;
  107. }
  108. public function getCreatedAt(): ?\DateTimeInterface
  109. {
  110. return $this->createdAt;
  111. }
  112. public function setCreatedAt(\DateTimeInterface $createdAt): static
  113. {
  114. $this->createdAt = $createdAt;
  115. return $this;
  116. }
  117. public function getEntidadColaboradora(): ?EntidadColaboradora
  118. {
  119. return $this->entidadColaboradora;
  120. }
  121. public function setEntidadColaboradora(?EntidadColaboradora $entidadColaboradora): static
  122. {
  123. $this->entidadColaboradora = $entidadColaboradora;
  124. return $this;
  125. }
  126. public function getNoticia(): ?Noticia
  127. {
  128. return $this->noticia;
  129. }
  130. public function setNoticia(?Noticia $noticia): static
  131. {
  132. $this->noticia = $noticia;
  133. return $this;
  134. }
  135. }