← Back
Editing: Rappel.php
<?php namespace App\Entity; use App\Repository\RappelRepository; use Doctrine\ORM\Mapping as ORM; #[ORM\Entity(repositoryClass: RappelRepository::class)] class Rappel { #[ORM\Id] #[ORM\GeneratedValue] #[ORM\Column(type: 'integer')] private ?int $id = null; #[ORM\ManyToOne(targetEntity: User::class, inversedBy: 'rappels')] #[ORM\JoinColumn(nullable: false, onDelete: 'CASCADE')] private ?User $agent = null; #[ORM\Column(type: 'datetime')] private \DateTimeInterface $createdAt; public function __construct() { $this->createdAt = new \DateTime(); } public function getId(): ?int { return $this->id; } public function getAgent(): ?User { return $this->agent; } public function setAgent(?User $agent): self { $this->agent = $agent; return $this; } public function getCreatedAt(): ?\DateTimeInterface { return $this->createdAt; } public function setCreatedAt(\DateTimeInterface $createdAt): self { $this->createdAt = $createdAt; return $this; } }
Save File
Cancel