mirror of
https://github.com/kevinveenbirkenbach/infinito.git
synced 2025-09-13 13:57:10 +02:00
Implemented homepage as source
This commit is contained in:
@@ -4,6 +4,10 @@ namespace Infinito\Controller;
|
||||
|
||||
use Symfony\Component\Routing\Annotation\Route;
|
||||
use Symfony\Component\HttpFoundation\Response;
|
||||
use Infinito\Domain\FixtureManagement\FixtureSource\HomepageFixtureSource;
|
||||
use Infinito\DBAL\Types\Meta\Right\LayerType;
|
||||
use Symfony\Component\HttpFoundation\RedirectResponse;
|
||||
use Infinito\DBAL\Types\RESTResponseType;
|
||||
|
||||
/**
|
||||
* This controller offers the standart routes for the template.
|
||||
@@ -17,6 +21,16 @@ final class DefaultController extends AbstractController
|
||||
*/
|
||||
public function homepage(): Response
|
||||
{
|
||||
return $this->render('standard/homepage.html.twig');
|
||||
// echo "Hello World!";
|
||||
// $url = $this->generateUrl('infinito_api_rest_layer_read', [
|
||||
// 'identity' => HomepageFixtureSource::SLUG,
|
||||
// 'layer' => LayerType::SOURCE
|
||||
// ]);
|
||||
// return new RedirectResponse($url);
|
||||
return $this->redirectToRoute('infinito_api_rest_layer_read', [
|
||||
'identity' => HomepageFixtureSource::SLUG,
|
||||
'layer' => LayerType::SOURCE,
|
||||
'_format' => RESTResponseType::HTML,
|
||||
]);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user