src/Admin/Entity/StdPagesApprovalComments.php line 15

Open in your IDE?
  1. <?php
  2. namespace App\Admin\Entity;
  3. use App\Admin\Enum\ApprovalStatus;
  4. use Doctrine\Common\Collections\ArrayCollection;
  5. use Doctrine\Common\Collections\Collection;
  6. use Doctrine\ORM\Mapping as ORM;
  7. /**
  8.  * StdPagesApprovalComments
  9.  */
  10. #[ORM\Table(name'std_pages_approval_comments')]
  11. #[ORM\Entity(repositoryClass'App\Admin\Repository\StdPagesApprovalCommentsRepository')]
  12. class StdPagesApprovalComments
  13. {
  14.     #[ORM\Column(name'id'type'integer'nullablefalseoptions: ['unsigned' => true'comment' => 'Unique identifier'])]
  15.     #[ORM\Id]
  16.     #[ORM\GeneratedValue(strategy'IDENTITY')]
  17.     private $id;
  18.     #[ORM\ManyToOne(targetEntityStdPagesApprovalStatus::class, inversedBy'comments')]
  19.     #[ORM\JoinColumn(name'approval_status_id'referencedColumnName'id'nullabletrueonDelete'CASCADE')]
  20.     private StdPagesApprovalStatus $approvalStatus;
  21.     #[ORM\ManyToOne(targetEntityStdUsers::class)]
  22.     #[ORM\JoinColumn(name'author_id'referencedColumnName'id'nullabletrueonDelete'SET NULL')]
  23.     private ?StdUsers $author null;
  24.     #[ORM\Column(name'comment'type'string'length255nullabletrueoptions: ['comment' => 'Comment of the Approval'])]
  25.     private string $comment;
  26.     #[ORM\Column(name'created_at'type'datetime_immutable'nullablefalseoptions: ['comment' => 'Date of the comment'])]
  27.     private \DateTimeImmutable $createdAt;
  28.     public function getId(): int
  29.     {
  30.         return $this->id;
  31.     }
  32.     public function getApprovalStatus(): StdPagesApprovalStatus
  33.     {
  34.         return $this->approvalStatus;
  35.     }
  36.     public function setApprovalStatus(StdPagesApprovalStatus|null $approvalStatus): void
  37.     {
  38.         $this->approvalStatus $approvalStatus;
  39.     }
  40.     public function getAuthor(): ?StdUsers
  41.     {
  42.         return $this->author;
  43.     }
  44.     public function setAuthor(?StdUsers $author): void
  45.     {
  46.         $this->author $author;
  47.     }
  48.     public function getComment()
  49.     {
  50.         return $this->comment;
  51.     }
  52.     public function setComment($comment): void
  53.     {
  54.         $this->comment $comment;
  55.     }
  56.     public function getCreatedAt(): \DateTimeImmutable
  57.     {
  58.         return $this->createdAt;
  59.     }
  60.     public function setCreatedAt(\DateTimeImmutable $createdAt): void
  61.     {
  62.         $this->createdAt $createdAt;
  63.     }
  64. }