public function indexAction()
    {
        $query = (string) $this->params()->fromQuery('query', null);
        $query = strlen($query) > 0 ? $query : null;

        $orderBy = (string) $this->params()->fromQuery('orderBy', null);
        $orderBy = strlen($orderBy) > 0 ? $orderBy : null;

        $sort = (string) $this->params()->fromQuery('sort', null);
        $sort = strlen($sort) > 0 ? $sort : null;

        $page  = (int) $this->params()->fromRoute('page', 1);
        $limit = $this->getOptions()->getDefaultItemsPerPage();

        $entities = $this->getService()->pagination($page, $limit, $query, $orderBy, $sort);

        $view = new ViewModel(array(
            'options'  => $this->getOptions(),
            'entities' => $entities,
            'query'    => $query,
            'orderBy'  => $orderBy,
            'sort'     => $sort,
        ));

        return $view;
    }