<?phpnamespace App\Entity\Menu;use Doctrine\DBAL\Types\Types;use Symfony\Bridge\Doctrine\Validator\Constraints\UniqueEntity;use Symfony\Component\Validator\Constraints as Assert;use Doctrine\ORM\Mapping as ORM;/** * Website Items * * @ORM\Table("menu_website_items") * @ORM\Entity(repositoryClass="App\Repository\Menu\WebsiteItemsRepository") * @ORM\HasLifecycleCallbacks() */class WebsiteItems{ /** * @var integer * * @ORM\Column(name="id", type="integer") * @ORM\Id * @ORM\GeneratedValue(strategy="AUTO") */ protected $id; /** * @var string * * @ORM\Column(name="created_at", type="datetime", nullable=true, options={"comment":"Date de création"}) */ private $createdAt; /** * @var string * * @ORM\Column(name="updated_at", type="datetime", nullable=true, options={"comment":"Date de mise à jour"}) */ private $updatedAt; /** * @var string $title * * @ORM\Column(name="title", type="string", length=255, nullable=true) */ private $title; /** * @var string $link * * @ORM\Column(name="link", type="string", length=255, nullable=true) */ private $link; /** * @var string $sequence * * @ORM\Column(name="sequence", type="integer", length=11, nullable=true) */ protected $sequence; /** * @var string * * @ORM\Column(name="type", type="string", length=255, nullable=true) */ private $type; /** * @var \Parents * * @ORM\ManyToOne(targetEntity="WebsiteParents") * @ORM\JoinColumns({ * @ORM\JoinColumn(name="parent_id", referencedColumnName="id", nullable=true) * }) */ protected $parent; /** * @var string $title * * @ORM\Column(name="description", type="text", nullable=true) */ private $description; /** * @var string $link * * @ORM\Column(name="linkPicture", type="text", nullable=true) */ private $linkPicture; /** * @ORM\PrePersist */ public function setCreatedAtValue(): void { $this->setCreatedAt(new \DateTime("now")); $this->setUpdatedAt(new \DateTime("now")); } /** * @ORM\PreUpdate */ public function setUpdatedAtValue(): void { $this->setUpdatedAt(new \DateTime("now")); } public function __toString() { return $this->title; } public function getId(): ?int { return $this->id; } public function getCreatedAt(): ?\DateTimeInterface { return $this->createdAt; } public function setCreatedAt(?\DateTimeInterface $createdAt): self { $this->createdAt = $createdAt; return $this; } public function getUpdatedAt(): ?\DateTimeInterface { return $this->updatedAt; } public function setUpdatedAt(?\DateTimeInterface $updatedAt): self { $this->updatedAt = $updatedAt; return $this; } public function getTitle(): ?string { return $this->title; } public function setTitle(?string $title): self { $this->title = $title; return $this; } public function getLink(): ?string { return $this->link; } public function setLink(?string $link): self { $this->link = $link; return $this; } public function getSequence(): ?int { return $this->sequence; } public function setSequence(?int $sequence): self { $this->sequence = $sequence; return $this; } public function getType(): ?string { return $this->type; } public function setType(?string $type): self { $this->type = $type; return $this; } public function getParent(): ?WebsiteParents { return $this->parent; } public function setParent(?WebsiteParents $parent): self { $this->parent = $parent; return $this; } public function getDescription(): ?string { return $this->description; } public function setDescription(?string $description): self { $this->description = $description; return $this; } public function getLinkPicture(): ?string { return $this->linkPicture; } public function setLinkPicture(?string $linkPicture): self { $this->linkPicture = $linkPicture; return $this; }}