protected function renderAdminForm(
        FormInterface $form,
        array $params = array(),
        $response = null,
        $template = self::TEMPLATE
    ){
        if (is_null($response)) {
            $code = Response::HTTP_OK;
            if ($form->isSubmitted() && !$form->isValid()) {
                $code = Response::HTTP_UNPROCESSABLE_ENTITY;
            }
            $response = new Response('', $code, array('Content-type' => 'text/html; charset=utf-8'));
        }

        $params = array_merge($params, array('form' => $form->createView()));

        return $this->render($template, $params, $response);
    }