From e741dddfc1d3f51e35c3c414ea1bfec8371d40e8 Mon Sep 17 00:00:00 2001 From: Kevin Adametz Date: Tue, 9 Jul 2019 14:29:42 +0200 Subject: [PATCH] Optimierung Darstellungen, kleine Bugs, SS-Sudan twig im Content --- .../Entity/TravelGuideRepository.php | 25 +++ trunk/src/AppBundle/Entity/TravelGuides.php | 161 ++++++++++++++++++ 2 files changed, 186 insertions(+) create mode 100644 trunk/src/AppBundle/Entity/TravelGuideRepository.php create mode 100644 trunk/src/AppBundle/Entity/TravelGuides.php diff --git a/trunk/src/AppBundle/Entity/TravelGuideRepository.php b/trunk/src/AppBundle/Entity/TravelGuideRepository.php new file mode 100644 index 00000000..29cad9b6 --- /dev/null +++ b/trunk/src/AppBundle/Entity/TravelGuideRepository.php @@ -0,0 +1,25 @@ +getEntityManager()->createQueryBuilder(); + $qb->select('c'); + $qb->from('AppBundle:CMSContent', 'c'); + $qb->where('c.slug = :slug'); + $qb->setParameter('slug', $slug); + $qb->setMaxResults(1); + return $qb->getQuery()->getOneOrNullResult(); + + } +} diff --git a/trunk/src/AppBundle/Entity/TravelGuides.php b/trunk/src/AppBundle/Entity/TravelGuides.php new file mode 100644 index 00000000..5cc11a64 --- /dev/null +++ b/trunk/src/AppBundle/Entity/TravelGuides.php @@ -0,0 +1,161 @@ +id; + } + + /** + * Set name + * + * @param string $name + * + * @return CMSContent + */ + public function setName($name) + { + $this->name = $name; + + return $this; + } + + /** + * Get name + * + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Set slug + * + * @param string $slug + * + * @return CMSContent + */ + public function setSlug($slug) + { + $this->slug = $slug; + + return $this; + } + + /** + * Get slug + * + * @return string + */ + public function getSlug() + { + return $this->slug; + } + + + /** + * Set fullText + * + * @param string $fullText + * + * @return CMSContent + */ + public function setFullText($fullText) + { + $this->fullText = $fullText; + + return $this; + } + + /** + * Get fullText + * + * @return string + */ + public function getFullText() + { + return $this->fullText; + } + + /** + * Set page + * + * @param \AppBundle\Entity\Page $page + * + * @return TravelGuideContent + */ + public function setPage(\AppBundle\Entity\Page $page = null) + { + $this->page = $page; + + return $this; + } + + /** + * Get page + * + * @return \AppBundle\Entity\Page + */ + public function getPage() + { + return $this->page; + } + +} +