From 31f3744ad9db36610519c95f8f56ab2afaa4c4e2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Julien=20Fastr=C3=A9?= Date: Mon, 21 Sep 2015 22:51:04 +0200 Subject: [PATCH] admin are redirected to admin section --- Controller/DefaultController.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Controller/DefaultController.php b/Controller/DefaultController.php index 52edfa046..ba44375ed 100644 --- a/Controller/DefaultController.php +++ b/Controller/DefaultController.php @@ -8,6 +8,11 @@ class DefaultController extends Controller { public function indexAction() { + if ($this->isGranted('ROLE_ADMIN')) { + + return $this->redirectToRoute('chill_main_admin_central'); + } + return $this->render('ChillMainBundle::layout.html.twig'); }