src/Entity/UserTitle.php line 10

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use App\Repository\UserTitleRepository;
  4. use Symfony\Component\Serializer\Annotation\Groups;
  5. use Doctrine\ORM\Mapping as ORM;
  6. #[ORM\Entity(repositoryClassUserTitleRepository::class)]
  7. class UserTitle
  8. {
  9.     #[Groups(['LogService'])]
  10.     #[ORM\Id]
  11.     #[ORM\GeneratedValue]
  12.     #[ORM\Column(type'integer')]
  13.     private $id;
  14.     #[Groups(['LogService'])]
  15.     #[ORM\Column(type'string'length255)]
  16.     private $title;
  17.     #[Groups(['LogService'])]
  18.     #[ORM\Column(type'datetime_immutable')]
  19.     private $validAt;
  20.     #[ORM\ManyToOne(targetEntityUser::class, inversedBy'userTitles')]
  21.     #[ORM\JoinColumn(nullablefalse)]
  22.     private $user;
  23.     #[ORM\Column(type'datetime_immutable')]
  24.     private $createdAt;
  25.      #[ORM\ManyToOne(targetEntityUser::class)]
  26.     #[ORM\JoinColumn(nullabletrue)]
  27.     private $createdBy;
  28.     #[ORM\Column(type'datetime_immutable'nullabletrue)]
  29.     private $updatedAt;
  30.     #[ORM\ManyToOne(targetEntityUser::class)]
  31.     #[ORM\JoinColumn(nullabletrue)]
  32.     private $updatedBy;
  33.    
  34.     public function getId(): ?int
  35.     {
  36.         return $this->id;
  37.     }
  38.     public function getTitle(): ?string
  39.     {
  40.         return $this->title;
  41.     }
  42.     public function setTitle(string $title): self
  43.     {
  44.         $this->title $title;
  45.         return $this;
  46.     }
  47.     public function getValidAt(): ?\DateTimeInterface
  48.     {
  49.         return $this->validAt;
  50.     }
  51.     public function setValidAt(\DateTimeInterface $validAt): self
  52.     {
  53.         $this->validAt $validAt;
  54.         return $this;
  55.     }
  56.     public function getUser(): ?User
  57.     {
  58.         return $this->user;
  59.     }
  60.     public function setUser(?User $user): self
  61.     {
  62.         $this->user $user;
  63.         return $this;
  64.     }
  65.     public function getCreatedAt(): ?\DateTimeInterface
  66.     {
  67.         return $this->createdAt;
  68.     }
  69.     public function setCreatedAt(\DateTimeInterface $createdAt): self
  70.     {
  71.         $this->createdAt $createdAt;
  72.         return $this;
  73.     }
  74.     public function getCreatedBy(): ?User
  75.     {
  76.         return $this->createdBy;
  77.     }
  78.     public function setCreatedBy(?User $createdBy): self
  79.     {
  80.         $this->createdBy $createdBy;
  81.         return $this;
  82.     }
  83.     public function getUpdatedAt(): ?\DateTimeInterface
  84.     {
  85.         return $this->updatedAt;
  86.     }
  87.     public function setUpdatedAt(?\DateTimeInterface $updatedAt): self
  88.     {
  89.         $this->updatedAt $updatedAt;
  90.         return $this;
  91.     }
  92.     public function getUpdatedBy(): ?User
  93.     {
  94.         return $this->updatedBy;
  95.     }
  96.     public function setUpdatedBy(?User $updatedBy): self
  97.     {
  98.         $this->updatedBy $updatedBy;
  99.         return $this;
  100.     }
  101. }