<?php
namespace App\Entity;
use App\Repository\AdmissionUserCommentRepository;
use Doctrine\DBAL\Types\Types;
use Doctrine\ORM\Mapping as ORM;
use Symfony\Component\Serializer\Annotation\Groups;
#[ORM\Entity(repositoryClass: AdmissionUserCommentRepository::class)]
class AdmissionUserComment
{
public const STATE_CONTACT_PENDING = 'contact_pending';
public const STATE_CONTACT_SUCCESS = 'contact_success';
public const TYPE_COMMENT_PRIMARY = 'bg-primary';
public const TYPE_COMMENT_SUCCESS = 'bg-success';
public const TYPE_COMMENT_WARNING = 'bg-warning';
#[ORM\Id]
#[ORM\GeneratedValue]
#[ORM\Column(type: 'integer')]
#[Groups(['list','au'])]
private ?int $id;
#[ORM\ManyToOne(targetEntity: AdmissionUser::class)]
#[Groups(['list'])]
private ?AdmissionUser $admissionUser;
#[ORM\Column(type: 'string', length: 255)]
#[Groups(['list','au'])]
private ?string $comment;
#[ORM\Column(type: 'string', length: 20)]
#[Groups(['list','au'])]
private ?string $state;
#[ORM\Column(type: 'string', length: 20)]
#[Groups(['list','au'])]
private ?string $type;
#[ORM\ManyToOne(targetEntity: User::class)]
#[Groups(['list','au'])]
private ?User $userCreated;
#[ORM\Column(type: 'datetime')]
#[Groups(['list','au'])]
private ?\DateTimeInterface $timeCreated;
#[ORM\Column(type: 'integer')]
#[Groups(['list','au'])]
private ?int $commentIndex;
public function getId(): ?int
{
return $this->id;
}
public function getAdmissionUser(): ?AdmissionUser
{
return $this->admissionUser;
}
public function setAdmissionUser(?AdmissionUser $admissionUser): self
{
$this->admissionUser = $admissionUser;
return $this;
}
public function getComment(): ?string
{
return $this->comment;
}
public function setComment(string $comment): self
{
$this->comment = $comment;
return $this;
}
public function getState(): ?string
{
return $this->state;
}
public function setState(string $state): self
{
$this->state = $state;
return $this;
}
public function getType(): ?string
{
return $this->type;
}
public function setType(string $type): self
{
$this->type = $type;
return $this;
}
public function getTimeCreated(): ?\DateTimeInterface
{
return $this->timeCreated;
}
public function setTimeCreated(\DateTimeInterface $timeCreated): self
{
$this->timeCreated = $timeCreated;
return $this;
}
public function getUserCreated(): ?User
{
return $this->userCreated;
}
public function setUserCreated(?User $userCreated): self
{
$this->userCreated = $userCreated;
return $this;
}
public function getCommentIndex(): ?int
{
return $this->commentIndex;
}
public function setCommentIndex(int $commentIndex): self
{
$this->commentIndex = $commentIndex;
return $this;
}
}