public function emailsDashboardAction(Request $request)
    {
        $form = $this->createForm(SentEmailType::class);
        $form->handleRequest($request);
        $searchParams = $form->getData();
        /** @var SentEmailRepository $repository */
        $repository = $this->getDoctrine()->getManager()->getRepository(SentEmail::class);
        $query = $repository->search($searchParams);
        $pagination = $this->get('knp_paginator')->paginate($query, $request->query->getInt('page', 1));

        return $this->render('AzineEmailBundle::emailsDashboard.html.twig',
            array('form' => $form->createView(), 'pagination' => $pagination));
    }