<?phpnamespace App\Entity\Pages;use App\Entity\Fiches\Articles;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;use Vich\UploaderBundle\Mapping\Annotation as Vich;use Symfony\Component\HttpFoundation\File\File;use Symfony\Component\HttpFoundation\File\UploadedFile;use Vich\UploaderBundle\Entity\File as EmbeddedFile;/** * Pages * * @ORM\Table("pages_contents") * @ORM\Entity(repositoryClass="App\Repository\Pages\ContentsRepository") * @ORM\HasLifecycleCallbacks() * @Vich\Uploadable */class Contents{ /** * @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 * * @ORM\Column(name="locale", type="string", length=255, nullable=true) */ private $locale; /** * @var string * * @ORM\Column(name="folder_slug", type="string", length=255, nullable=true) */ private $folderSlug; /** * @var string * * @ORM\Column(name="folder_slug2", type="string", length=255, nullable=true) */ private $folderSlug2; /** * @var string * * @ORM\Column(name="folder_slug3", type="string", length=255, nullable=true) */ private $folderSlug3; /** * @var string * * @ORM\Column(name="title", type="string", length=255, nullable=true) */ private $title; /** * @var string * * @ORM\Column(name="tag", type="string", length=255, nullable=true) */ private $tag; /** * @var string * * @ORM\Column(name="status", type="string", length=255, nullable=true) */ private $status; /** * @var string * * @ORM\Column(name="theme", type="string", length=255, nullable=true) */ private $theme; /** * @var string * * @ORM\Column(name="short_title", type="string", length=255, nullable=true) */ private $shortTitle; /** * @var string * * @ORM\Column(name="short_description", type="text", nullable=true) */ private $shortDescription; /** * @var string * * @ORM\Column(name="description_cover", type="text", nullable=true) */ private $descriptionCover; /** * @var string * * @ORM\Column(name="description_content", type="text", nullable=true) */ private $descriptionContent; /** * @var string * * @ORM\Column(name="description_content_end", type="text", nullable=true) */ private $descriptionContentEnd; /** * @var string * * @ORM\Column(name="title_mitillo_plus", type="text", nullable=true) */ private $titleMirtilloPlus; /** * @var string * * @ORM\Column(name="path_mirtillo_plus", type="text", nullable=true) */ private $pathMirtilloPlus; /** * @var string * * @ORM\Column(name="description_mirtillo_plus", type="text", nullable=true) */ private $descriptionMirtilloPlus; /** * @var string * * @ORM\Column(name="title_button_mirtillo_plus", type="text", nullable=true) */ private $titleButtonMirtilloPlus; /** * @var string * * @ORM\Column(name="description_after_cover", type="text", nullable=true) */ private $descriptionAfterContent; /** * @var \Pages * * @ORM\ManyToOne(targetEntity="Pages") * @ORM\JoinColumns({ * @ORM\JoinColumn(name="page_id", referencedColumnName="id", nullable=true) * }) */ protected $page; /** * @ORM\PrePersist */ public function setCreatedAtValue(): void { $this->setCreatedAt(new \DateTime("now")); $this->setUpdatedAt(new \DateTime("now")); $this->setStatus("brouillon"); } /** * @ORM\PreUpdate */ public function setUpdatedAtValue(): void { $this->setUpdatedAt(new \DateTime("now")); } public function __toString() { return (string)$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 getFolderSlug(): ?string { return $this->folderSlug; } public function setFolderSlug(?string $folderSlug): self { $this->folderSlug = $folderSlug; return $this; } public function getFolderSlug2(): ?string { return $this->folderSlug2; } public function setFolderSlug2(?string $folderSlug2): self { $this->folderSlug2 = $folderSlug2; return $this; } public function getTitle(): ?string { return $this->title; } public function setTitle(?string $title): self { $this->title = $title; return $this; } public function getStatus(): ?string { return $this->status; } public function setStatus(?string $status): self { $this->status = $status; return $this; } public function getShortTitle(): ?string { return $this->shortTitle; } public function setShortTitle(?string $shortTitle): self { $this->shortTitle = $shortTitle; return $this; } public function getShortDescription(): ?string { return $this->shortDescription; } public function setShortDescription(?string $shortDescription): self { $this->shortDescription = $shortDescription; return $this; } public function getDescriptionCover(): ?string { return $this->descriptionCover; } public function setDescriptionCover(?string $descriptionCover): self { $this->descriptionCover = $descriptionCover; return $this; } public function getDescriptionContent(): ?string { return $this->descriptionContent; } public function setDescriptionContent(?string $descriptionContent): self { $this->descriptionContent = $descriptionContent; return $this; } public function getTitleMirtilloPlus(): ?string { return $this->titleMirtilloPlus; } public function setTitleMirtilloPlus(?string $titleMirtilloPlus): self { $this->titleMirtilloPlus = $titleMirtilloPlus; return $this; } public function getPathMirtilloPlus(): ?string { return $this->pathMirtilloPlus; } public function setPathMirtilloPlus(?string $pathMirtilloPlus): self { $this->pathMirtilloPlus = $pathMirtilloPlus; return $this; } public function getDescriptionAfterContent(): ?string { return $this->descriptionAfterContent; } public function setDescriptionAfterContent(?string $descriptionAfterContent): self { $this->descriptionAfterContent = $descriptionAfterContent; return $this; } public function getPage(): ?Pages { return $this->page; } public function setPage(?Pages $page): self { $this->page = $page; return $this; } public function getFolderSlug3(): ?string { return $this->folderSlug3; } public function setFolderSlug3(?string $folderSlug3): self { $this->folderSlug3 = $folderSlug3; return $this; } public function getDescriptionContentEnd(): ?string { return $this->descriptionContentEnd; } public function setDescriptionContentEnd(?string $descriptionContentEnd): self { $this->descriptionContentEnd = $descriptionContentEnd; return $this; } public function getDescriptionMirtilloPlus(): ?string { return $this->descriptionMirtilloPlus; } public function setDescriptionMirtilloPlus(?string $descriptionMirtilloPlus): self { $this->descriptionMirtilloPlus = $descriptionMirtilloPlus; return $this; } public function getTitleButtonMirtilloPlus(): ?string { return $this->titleButtonMirtilloPlus; } public function setTitleButtonMirtilloPlus(?string $titleButtonMirtilloPlus): self { $this->titleButtonMirtilloPlus = $titleButtonMirtilloPlus; return $this; } public function getTheme(): ?string { return $this->theme; } public function setTheme(?string $theme): self { $this->theme = $theme; return $this; } public function getTag(): ?string { return $this->tag; } public function setTag(?string $tag): self { $this->tag = $tag; return $this; } public function getLocale(): ?string { return $this->locale; } public function setLocale(?string $locale): static { $this->locale = $locale; return $this; }}