Convert HomeController to use Menu annotation instead of base controller #222

This commit is contained in:
Kendrick Chan 2019-06-07 01:22:09 +08:00
parent fa9bbe8989
commit 841011d3d0

View file

@ -2,14 +2,16 @@
namespace App\Controller; namespace App\Controller;
use App\Ramcar\BaseController; use Catalyst\MenuBundle\Annotation\Menu;
use Symfony\Bundle\FrameworkBundle\Controller\Controller;
class HomeController extends BaseController class HomeController extends Controller
{ {
/**
* @Menu(selected="home")
*/
public function index() public function index()
{ {
$params = $this->initParameters('home'); return $this->render('home.html.twig');
return $this->render('home.html.twig', $params);
} }
} }