src/Entity/CancellationSurvey.php line 10

Open in your IDE?
  1. <?php
  2. namespace App\Entity;
  3. use App\Repository\CancellationSurveyRepository;
  4. use Doctrine\DBAL\Types\Types;
  5. use Doctrine\ORM\Mapping as ORM;
  6. #[ORM\Entity(repositoryClassCancellationSurveyRepository::class)]
  7. class CancellationSurvey
  8. {
  9.     #[ORM\Id]
  10.     #[ORM\GeneratedValue]
  11.     #[ORM\Column]
  12.     private ?int $id null;
  13.     #[ORM\ManyToOne(inversedBy'cancellationSurveys')]
  14.     #[ORM\JoinColumn(nullablefalse)]
  15.     private ?User $user null;
  16.     #[ORM\Column]
  17.     private array $answers = [];
  18.     #[ORM\Column(typeTypes::DATETIME_MUTABLE)]
  19.     private ?\DateTimeInterface $created_at null;
  20.     #[ORM\Column(typeTypes::DATETIME_MUTABLEnullabletrue)]
  21.     private ?\DateTimeInterface $updated_at null;
  22.     public function getId(): ?int
  23.     {
  24.         return $this->id;
  25.     }
  26.     public function getUser(): ?User
  27.     {
  28.         return $this->user;
  29.     }
  30.     public function setUser(?User $user): static
  31.     {
  32.         $this->user $user;
  33.         return $this;
  34.     }
  35.     public function getAnswers(): array
  36.     {
  37.         return $this->answers;
  38.     }
  39.     public function setAnswers(array $answers): static
  40.     {
  41.         $this->answers $answers;
  42.         return $this;
  43.     }
  44.     public function getCreatedAt(): ?\DateTimeInterface
  45.     {
  46.         return $this->created_at;
  47.     }
  48.     public function setCreatedAt(\DateTimeInterface $created_at): static
  49.     {
  50.         $this->created_at $created_at;
  51.         return $this;
  52.     }
  53.     public function getUpdatedAt(): ?\DateTimeInterface
  54.     {
  55.         return $this->updated_at;
  56.     }
  57.     public function setUpdatedAt(?\DateTimeInterface $updated_at): static
  58.     {
  59.         $this->updated_at $updated_at;
  60.         return $this;
  61.     }
  62. }