<?php
namespace App\Entity;
use App\Repository\NotificationRepository;
use Doctrine\ORM\Mapping as ORM;
use App\Traits\EntityDateTimeAbleTrait;
#[ORM\Entity(repositoryClass: NotificationRepository::class)]
#[ORM\HasLifecycleCallbacks]
class Notification
{
use EntityDateTimeAbleTrait;
const TYPE_IDENTITY = 1;
const TYPE_RESIDENCE_PERMIT = 2;
const EXPRIRE_TYPE_TWO_MONTH = 60;
const EXPRIRE_TYPE_ONE_MONTH = 30;
const EXPRIRE_TYPE_THREE_WEEK = 21;
const EXPRIRE_TYPE_TWO_WEEK = 14;
const EXPRIRE_TYPE_ONE_WEEK = 7;
#[ORM\Id]
#[ORM\GeneratedValue]
#[ORM\Column(type: 'integer')]
private $id;
#[ORM\ManyToOne(targetEntity: Profile::class, inversedBy: 'notifications')]
private ?\App\Entity\Profile $profile = null;
#[ORM\Column(type: 'integer', nullable: true)]
private ?int $type = null;
#[ORM\Column(type: 'integer', nullable: true)]
private ?int $expireType = null;
#[ORM\Column(type: 'boolean', nullable: true)]
private ?bool $isSeen = null;
public function getId(): ?int
{
return $this->id;
}
public function getProfile(): ?Profile
{
return $this->profile;
}
public function setProfile(?Profile $profile): self
{
$this->profile = $profile;
return $this;
}
public function getType(): ?int
{
return $this->type;
}
public function setType(?int $type): self
{
$this->type = $type;
return $this;
}
public function getExpireType(): ?int
{
return $this->expireType;
}
public function setExpireType(?int $expireType): self
{
$this->expireType = $expireType;
return $this;
}
public function getIsSeen(): ?bool
{
return $this->isSeen;
}
public function setIsSeen(?bool $isSeen): self
{
$this->isSeen = $isSeen;
return $this;
}
}