src/Entity/StaffDeputation.php line 11

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use App\Repository\StaffDeputationRepository;
  4. use Doctrine\ORM\Mapping as ORM;
  5. use Gedmo\Mapping\Annotation as Gedmo;
  6. use Symfony\Component\Validator\Constraints as Assert;
  7. #[ORM\Entity(repositoryClassStaffDeputationRepository::class), ORM\Table(name'staff_deputations')]
  8. class StaffDeputation
  9. {
  10.     #[ORM\IdORM\GeneratedValueORM\Column(type'integer')]
  11.     private $id;
  12.     #[ORM\Column(type'string'length100), Assert\NotBlank]
  13.     private $place;
  14.     #[ORM\Column(type'string'length100), Assert\NotBlank]
  15.     private $period;
  16.     #[ORM\Column(type'string'length100)]
  17.     private $depOrder;
  18.     #[Gedmo\Timestampable(on'create'), ORM\Column(type'datetime')]
  19.     private $createdAt;
  20.     #[Gedmo\Timestampable(on'update'), ORM\Column(type'datetime')]
  21.     private $udpatedAt;
  22.     #[ORM\ManyToOne(targetEntityStaffProfile::class, inversedBy'deputations'), ORM\JoinColumn(nullablefalse)]
  23.     private $profile;
  24.     public function getId(): ?int
  25.     {
  26.         return $this->id;
  27.     }
  28.     public function getPlace(): ?string
  29.     {
  30.         return $this->place;
  31.     }
  32.     public function setPlace(string $place): self
  33.     {
  34.         $this->place strip_tags($place);
  35.         return $this;
  36.     }
  37.     public function getPeriod(): ?string
  38.     {
  39.         return $this->period;
  40.     }
  41.     public function setPeriod(string $period): self
  42.     {
  43.         $this->period strip_tags($period);
  44.         return $this;
  45.     }
  46.     public function getDepOrder(): ?string
  47.     {
  48.         return $this->depOrder;
  49.     }
  50.     public function setDepOrder(string $depOrder): self
  51.     {
  52.         $this->depOrder $depOrder;
  53.         return $this;
  54.     }
  55.     public function getCreatedAt(): ?\DateTimeInterface
  56.     {
  57.         return $this->createdAt;
  58.     }
  59.     public function getUdpatedAt(): ?\DateTimeInterface
  60.     {
  61.         return $this->udpatedAt;
  62.     }
  63.     public function getProfile(): ?StaffProfile
  64.     {
  65.         return $this->profile;
  66.     }
  67.     public function setProfile(?StaffProfile $profile): self
  68.     {
  69.         $this->profile $profile;
  70.         return $this;
  71.     }
  72. }