src/Controller/Frontend/FooterController.php line 21

Open in your IDE?
  1. <?php
  2. namespace App\Controller\Frontend;
  3. use Symfony\Component\HttpFoundation\Response;
  4. use Symfony\Component\Routing\Annotation\Route;
  5. use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
  6. use App\Service\TextHelper;
  7. use App\Entity\Section;
  8. class FooterController extends AbstractController
  9. {
  10.    /**
  11.     * Matches / es exactly
  12.     *
  13.     * @Route("{_locale}/social", name="social")
  14.     */
  15.    public function index(TextHelper $textHelper)
  16.    {
  17.        //sdfdsfssaaaaa
  18.       $oneSection $this->getDoctrine()->getRepository(Section::Class)->findOneBy(['code' => 'footer']);
  19.       $text       = ($textHelper->getBySection($oneSection)) ? $textHelper->getBySection($oneSection) : [];
  20.       return $this->render('Frontend/footer/footer.html.twig', ['text' => $text]);
  21.    }
  22. }