<?phpnamespace App\Entity;use App\Repository\MessageDirecteurAuxParentsRepository;use Doctrine\ORM\Mapping as ORM;/** * @ORM\Entity(repositoryClass=MessageDirecteurAuxParentsRepository::class) */class MessageDirecteurAuxParents{ const STATE_OPEN = "open"; const STATE_REJECTED = "rejected"; const STATE_VALIDATED = "validated"; /** * @ORM\Id * @ORM\GeneratedValue * @ORM\Column(type="integer") */ private $id; /** * @ORM\ManyToOne(targetEntity=Contact::class) * @ORM\JoinColumn(nullable=false) */ private $directeur; /** * @ORM\Column(type="boolean", nullable=true) */ private $isValidated; /** * @ORM\Column(type="text", nullable=true) */ private $text; /** * @ORM\Column(type="string", length=255, nullable=true) */ private $meteo; /** * @ORM\ManyToOne(targetEntity=SejourSession::class, inversedBy="messageDirecteurAuxParents") * @ORM\JoinColumn(nullable=false) */ private $sejourSession; /** * @ORM\Column(type="datetime") */ private $createdDate; /** * @ORM\Column(type="string", length=255) */ private $status; public function getId(): ?int { return $this->id; } public function getDirecteur(): ?Contact { return $this->directeur; } public function setDirecteur(?Contact $directeur): self { $this->directeur = $directeur; return $this; } public function getIsValidated(): ?bool { return $this->isValidated; } public function setIsValidated(?bool $isValidated): self { $this->isValidated = $isValidated; return $this; } public function getText(): ?string { return $this->text; } public function setText(?string $text): self { $this->text = $text; return $this; } public function getMeteo(): ?string { return $this->meteo; } public function setMeteo(?string $meteo): self { $this->meteo = $meteo; return $this; } public function getSejourSession(): ?SejourSession { return $this->sejourSession; } public function setSejourSession(?SejourSession $sejourSession): self { $this->sejourSession = $sejourSession; return $this; } public function getCreatedDate(): ?\DateTimeInterface { return $this->createdDate; } public function setCreatedDate(\DateTimeInterface $createdDate): self { $this->createdDate = $createdDate; return $this; } public function getStatus(): ?string { return $this->status; } public function setStatus(string $status): self { $this->status = $status; return $this; } public function __construct() { $this->createdDate = new \DateTime(); $this->text = "Chers Parents, bonsoir, <br/><br/>"; }}