<?phpnamespace App\Entity;use App\Repository\DecisionRepository;use DateTimeImmutable;use Doctrine\Common\Collections\ArrayCollection;use Doctrine\Common\Collections\Collection;use Doctrine\DBAL\Types\Types;use Doctrine\ORM\Mapping as ORM;#[ORM\Entity(repositoryClass: DecisionRepository::class)]class Decision{ #[ORM\Id] #[ORM\GeneratedValue] #[ORM\Column] private ?int $id = null; #[ORM\Column(length: 255)] private ?string $label = null; #[ORM\Column(type: 'datetime_immutable', nullable: true)] private ?DateTimeImmutable $instructionDate = null; #[ORM\Column(type: 'datetime_immutable', nullable: true)] private ?DateTimeImmutable $endDate = null; #[ORM\Column(type: Types::TEXT, nullable: true)] private ?string $observation = null; #[ORM\ManyToOne] #[ORM\JoinColumn(nullable: false, onDelete: 'CASCADE')] private ?Meeting $meeting = null; #[ORM\ManyToOne] #[ORM\JoinColumn(nullable: false)] private ?Structure $structure = null; #[ORM\ManyToOne] #[ORM\JoinColumn(nullable: true)] private ?ExecutionLevel $executionLevel = null; #[ORM\ManyToMany(targetEntity: User::class, inversedBy: 'decisions')] private Collection $monitoringOfficer; #[ORM\Column(length: 255, nullable: true)] private ?string $attachments = null; #[ORM\ManyToOne] private ?User $createdBy = null; #[ORM\ManyToOne] private ?User $updatedBy = null; #[ORM\Column] private ?DateTimeImmutable $createdAt = null; #[ORM\Column(nullable: true)] private ?DateTimeImmutable $updatedAt = null; #[ORM\ManyToOne(inversedBy: 'decisions')] private ?Structure $structrue = null; public function __construct() { $this->monitoringOfficer = new ArrayCollection(); $this->createdAt = new DateTimeImmutable(); $this->updatedAt = new DateTimeImmutable(); } public function getId(): ?int { return $this->id; } public function getLabel(): ?string { return $this->label; } public function setLabel(string $label): self { $this->label = $label; return $this; } public function getInstructionDate(): ?DateTimeImmutable { return $this->instructionDate; } public function setInstructionDate(DateTimeImmutable $instructionDate): self { $this->instructionDate = $instructionDate; return $this; } public function getEndDate(): ?DateTimeImmutable { return $this->endDate; } public function setEndDate(?DateTimeImmutable $endDate): self { $this->endDate = $endDate; return $this; } public function getObservation(): ?string { return $this->observation; } public function setObservation(?string $observation): self { $this->observation = $observation; return $this; } public function getMeeting(): ?Meeting { return $this->meeting; } public function setMeeting(?Meeting $meeting): self { $this->meeting = $meeting; return $this; } public function getStructure(): ?Structure { return $this->structure; } public function setStructure(?Structure $structure): self { $this->structure = $structure; return $this; } public function getExecutionLevel(): ?ExecutionLevel { return $this->executionLevel; } public function setExecutionLevel(?ExecutionLevel $executionLevel): self { $this->executionLevel = $executionLevel; return $this; } /** * @return Collection<int, User> */ public function getMonitoringOfficer(): Collection { return $this->monitoringOfficer; } public function addMonitoringOfficer(User $monitoringOfficer): self { if (!$this->monitoringOfficer->contains($monitoringOfficer)) { $this->monitoringOfficer->add($monitoringOfficer); } return $this; } public function removeMonitoringOfficer(User $monitoringOfficer): self { $this->monitoringOfficer->removeElement($monitoringOfficer); return $this; } public function getAttachments(): ?string { return $this->attachments; } public function setAttachments(?string $attachments): self { $this->attachments = $attachments; return $this; } public function getCreatedBy(): ?User { return $this->createdBy; } public function setCreatedBy(?User $createdBy): self { $this->createdBy = $createdBy; return $this; } public function getUpdatedBy(): ?User { return $this->updatedBy; } public function setUpdatedBy(?User $updatedBy): self { $this->updatedBy = $updatedBy; return $this; } public function getCreatedAt(): ?DateTimeImmutable { return $this->createdAt; } public function setCreatedAt(DateTimeImmutable $createdAt): self { $this->createdAt = $createdAt; return $this; } public function getUpdatedAt(): ?DateTimeImmutable { return $this->updatedAt; } public function setUpdatedAt(?DateTimeImmutable $updatedAt): self { $this->updatedAt = $updatedAt; return $this; } public function getStructrue(): ?Structure { return $this->structrue; } public function setStructrue(?Structure $structrue): static { $this->structrue = $structrue; return $this; }}