src/Entity/Children.php line 9

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use Symfony\Component\Serializer\Annotation\Groups;
  4. use Doctrine\ORM\Mapping as ORM;
  5. #[ORM\Entity(repositoryClass'App\Repository\ChildrenRepository')]
  6. class Children
  7. {
  8.     #[Groups(['LogService'])]
  9.     #[ORM\Id]
  10.     #[ORM\GeneratedValue]
  11.     #[ORM\Column(type'integer')]
  12.     private $id;
  13.     #[Groups(['LogService'])]
  14.     #[ORM\Column(type'string'length255)]
  15.     private $fullName;
  16.     #[Groups(['LogService'])]
  17.     #[ORM\Column(type'string'length32nullabletrue)]
  18.     private $gender;
  19.     #[Groups(['LogService'])]
  20.     #[ORM\Column(type'date'nullabletrue)]
  21.     private $birthDate;
  22.     #[ORM\ManyToOne(targetEntity'App\Entity\PersonalInfo'inversedBy'childrens')]
  23.     #[ORM\JoinColumn(nullablefalse)]
  24.     private $personalInfo;
  25.     public function getId(): ?int
  26.     {
  27.         return $this->id;
  28.     }
  29.     public function getFullName(): ?string
  30.     {
  31.         return $this->fullName;
  32.     }
  33.     public function setFullName(string $fullName): self
  34.     {
  35.         $this->fullName $fullName;
  36.         return $this;
  37.     }
  38.     public function getGender(): ?string
  39.     {
  40.         return $this->gender;
  41.     }
  42.     public function setGender(?string $gender): self
  43.     {
  44.         $this->gender $gender;
  45.         return $this;
  46.     }
  47.     public function getBirthDate(): ?\DateTimeInterface
  48.     {
  49.         return $this->birthDate;
  50.     }
  51.     public function setBirthDate(?\DateTimeInterface $birthDate): self
  52.     {
  53.         $this->birthDate $birthDate;
  54.         return $this;
  55.     }
  56.     public function getPersonalInfo(): ?PersonalInfo
  57.     {
  58.         return $this->personalInfo;
  59.     }
  60.     public function setPersonalInfo(?PersonalInfo $personalInfo): self
  61.     {
  62.         $this->personalInfo $personalInfo;
  63.         return $this;
  64.     }
  65. }