Sulu\Bundle\CategoryBundle\Controller\CategoryController::getAction PHP Метод

getAction() публичный Метод

Returns the category which is assigned to the given id.
public getAction ( $id, Request $request ) : Response
$id
$request Symfony\Component\HttpFoundation\Request
Результат Symfony\Component\HttpFoundation\Response
    public function getAction($id, Request $request)
    {
        $locale = $this->getRequestParameter($request, 'locale', true);
        $findCallback = function ($id) use($locale) {
            $entity = $this->getCategoryManager()->findById($id);
            return $this->getCategoryManager()->getApiObject($entity, $locale);
        };
        $view = $this->responseGetById($id, $findCallback);
        return $this->handleView($view);
    }