<?phpnamespace App\Entity;use App\Repository\HistoryRepository;use Doctrine\Common\Collections\ArrayCollection;use Doctrine\Common\Collections\Collection;use Doctrine\ORM\Mapping as ORM;use Gedmo\Mapping\Annotation as Gedmo;/** * @ORM\Entity(repositoryClass=HistoryRepository::class) */class History{ /** * @ORM\Id * @ORM\GeneratedValue * @ORM\Column(type="integer") */ private $id; /** * @ORM\Column(type="string", length=255) */ private $comment; /** * @ORM\Column(type="string") */ private $statut; /** * @ORM\ManyToOne(targetEntity=Agency::class, inversedBy="histories") */ private $agency; /** * @ORM\ManyToOne(targetEntity=Bike::class, inversedBy="histories") * @ORM\JoinColumn(name="bike_id", referencedColumnName="id", nullable=true) */ private $bike; /** * @ORM\ManyToOne(targetEntity=Accessory::class, inversedBy="histories") * @ORM\JoinColumn(name="accessory_id", referencedColumnName="id", nullable=true) */ private $accessory; /** * @ORM\ManyToOne(targetEntity=Order::class, inversedBy="histories") */ private $book; /** * @ORM\Column(type="datetime_immutable") * @Gedmo\Timestampable(on="create") */ private $created_at; /** * @ORM\Column(type="datetime_immutable") * @Gedmo\Timestampable(on="update") */ private $updated_at; public function __construct() { } public function getId(): ?int { return $this->id; } public function getComment(): ?string { return $this->comment; } public function setComment(string $comment): self { $this->comment = $comment; return $this; } public function getStatut(): ?string { return $this->statut; } public function setStatut(string $statut): self { $this->statut = $statut; return $this; } public function getAgency(): ?Agency { return $this->agency; } public function setAgency(?Agency $agency): self { $this->agency = $agency; return $this; } public function getBike(): ?Bike { return $this->bike; } public function setBike(?Bike $bike): self { $this->bike = $bike; return $this; } public function getAccessory(): ?Accessory { return $this->accessory; } public function setAccessory(?Accessory $accessory): self { $this->accessory = $accessory; return $this; } public function getBook(): ?Order { return $this->book; } public function setBook(?Order $book): self { $this->book = $book; return $this; } public function getCreatedAt(): ?\DateTimeImmutable { return $this->created_at; } public function setCreatedAt(\DateTimeImmutable $created_at): self { $this->created_at = $created_at; return $this; } public function getUpdatedAt(): ?\DateTimeImmutable { return $this->updated_at; } public function setUpdatedAt(\DateTimeImmutable $updated_at): self { $this->updated_at = $updated_at; return $this; }}