Networking\InitCmsBundle\Controller\MenuItemAdminController::ajaxControllerAction PHP Méthode

ajaxControllerAction() public méthode

public ajaxControllerAction ( Request $request ) : Symfony\Component\HttpFoundation\JsonResponse
$request Symfony\Component\HttpFoundation\Request
Résultat Symfony\Component\HttpFoundation\JsonResponse
    public function ajaxControllerAction(Request $request)
    {
        $operation = $request->request->get('operation') ? $request->request->get('operation') : $request->query->get('operation');
        if (!$operation) {
            throw new NotFoundHttpException();
        }
        return new JsonResponse($this->{$operation}());
    }