implement new breadcrumb on image and document edition in the catalog

This commit is contained in:
Manuel Raynaud
2014-06-11 10:29:52 +02:00
parent afe48b2d33
commit 476bda3d4a
11 changed files with 220 additions and 20 deletions

View File

@@ -291,7 +291,7 @@ abstract class BaseController extends ContainerAware
protected function getRouteFromRouter($routerName, $routeId, $parameters = array(), $referenceType = Router::ABSOLUTE_URL)
{
/** @var Router $router */
$router = $this->container->get($routerName);
$router = $this->getRouter($routerName);
if ($router == null) {
throw new \InvalidArgumentException(sprintf("Router '%s' does not exists.", $routerName));
@@ -300,6 +300,15 @@ abstract class BaseController extends ContainerAware
return $router->generate($routeId, $parameters, $referenceType);
}
/**
* @param $routerName
* @return Router
*/
protected function getRouter($routerName)
{
return $this->container->get($routerName);
}
/**
* Return a 404 error
* @throws \Symfony\Component\HttpKernel\Exception\NotFoundHttpException