Esempio n. 1
0
 protected function initQueryBuilders()
 {
     if (null === $this->queryBuilder) {
         $this->queryBuilder = $this->baseQueryBuilder->buildQuery();
         $this->countQueryBuilder = clone $this->queryBuilder;
         $this->countQueryBuilder->resetDQLPart('orderBy');
     }
 }
Esempio n. 2
0
 public function getPager()
 {
     $sort = $this->getSort();
     unset($sort['column']);
     $this->queryBuilder->setSort($sort);
     $this->queryBuilder->setCriteria($this->state->get('criteria'));
     $this->pager->setPage($this->state->get('page'));
     $this->pager->setQueryBuilder($this->queryBuilder);
     return $this->pager;
 }