src/Entity/Notificacion.php line 11

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use App\Repository\NotificacionRepository;
  4. use Doctrine\ORM\Mapping as ORM;
  5. /**
  6.  * @ORM\Entity(repositoryClass=NotificacionRepository::class)
  7.  */
  8. class Notificacion
  9. {
  10.     /**
  11.      * @ORM\Id()
  12.      * @ORM\GeneratedValue()
  13.      * @ORM\Column(type="integer")
  14.      */
  15.     private $id;
  16.     /**
  17.      * @ORM\Column(type="string", length=255, nullable=true)
  18.      */
  19.     private $asunto;
  20.     /**
  21.      * @ORM\Column(type="string", length=255, nullable=true)
  22.      */
  23.     private $contenido;
  24.     /**
  25.      * @ORM\ManyToOne(targetEntity=TipoNotificacion::class, inversedBy="notificaciones")
  26.      * @ORM\JoinColumn(nullable=false)
  27.      */
  28.     private $tipoNotificacion;
  29.     /**
  30.      * @ORM\Column(type="datetime", nullable=true)
  31.      */
  32.     private $fecha;
  33.     /**
  34.      * @ORM\ManyToOne(targetEntity=User::class, inversedBy="notificaciones")
  35.      * @ORM\JoinColumn(nullable=false)
  36.      */
  37.     private $user;
  38.     /**
  39.      * @ORM\Column(type="boolean")
  40.      */
  41.     private $vista;
  42.     public function getId(): ?int
  43.     {
  44.         return $this->id;
  45.     }
  46.     public function getAsunto(): ?string
  47.     {
  48.         return $this->asunto;
  49.     }
  50.     public function setAsunto(?string $asunto): self
  51.     {
  52.         $this->asunto $asunto;
  53.         return $this;
  54.     }
  55.     public function getContenido(): ?string
  56.     {
  57.         return $this->contenido;
  58.     }
  59.     public function setContenido(?string $contenido): self
  60.     {
  61.         $this->contenido $contenido;
  62.         return $this;
  63.     }
  64.     public function getFecha(): ?\DateTimeInterface
  65.     {
  66.         return $this->fecha;
  67.     }
  68.     public function setFecha(\DateTimeInterface $fecha): self
  69.     {
  70.         $this->fecha $fecha;
  71.         return $this;
  72.     }
  73.     public function getTipoNotificacion(): ?TipoNotificacion
  74.     {
  75.         return $this->tipoNotificacion;
  76.     }
  77.     public function setTipoNotificacion(?TipoNotificacion $tipoNotificacion): self
  78.     {
  79.         $this->tipoNotificacion $tipoNotificacion;
  80.         return $this;
  81.     }
  82.     public function getUser(): ?User
  83.     {
  84.         return $this->user;
  85.     }
  86.     public function setUser(?User $user): self
  87.     {
  88.         $this->user $user;
  89.         return $this;
  90.     }
  91.     public function getVista(): ?bool
  92.     {
  93.         return $this->vista;
  94.     }
  95.     public function setVista(bool $vista): self
  96.     {
  97.         $this->vista $vista;
  98.         return $this;
  99.     }
  100. }