vendor/sulu/sulu/src/Sulu/Bundle/WebsiteBundle/Controller/DefaultController.php line 31

Open in your IDE?
  1. <?php
  2. /*
  3.  * This file is part of Sulu.
  4.  *
  5.  * (c) Sulu GmbH
  6.  *
  7.  * This source file is subject to the MIT license that is bundled
  8.  * with this source code in the file LICENSE.
  9.  */
  10. namespace Sulu\Bundle\WebsiteBundle\Controller;
  11. use Sulu\Component\Content\Compat\StructureInterface;
  12. use Symfony\Component\HttpFoundation\Response;
  13. /**
  14.  * Default Controller for rendering templates, uses the themes from the ClientWebsiteBundle.
  15.  */
  16. class DefaultController extends WebsiteController
  17. {
  18.     /**
  19.      * Loads the content from the request (filled by the route provider) and creates a response with this content and
  20.      * the appropriate cache headers.
  21.      *
  22.      * @param bool $preview
  23.      * @param bool $partial
  24.      *
  25.      * @return Response
  26.      */
  27.     public function indexAction(StructureInterface $structure$preview false$partial false)
  28.     {
  29.         $response $this->renderStructure(
  30.             $structure,
  31.             [],
  32.             $preview,
  33.             $partial
  34.         );
  35.         return $response;
  36.     }
  37. }