Skip to content

Commit

Permalink
Disable collection fetch for the findBy() paginator
Browse files Browse the repository at this point in the history
This change is related to the changes introduced by this PR:
javiereguiluz@d171056
  • Loading branch information
javiereguiluz committed Jan 17, 2015
1 parent 69bfc59 commit 98eb5ea
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Controller/AdminController.php
Original file line number Diff line number Diff line change
Expand Up @@ -395,7 +395,7 @@ protected function findBy($entityClass, $searchQuery, array $searchableFields, $
$query->orWhere("entity.$name LIKE :query")->setParameter('query', '%'.$searchQuery.'%');
}

$paginator = new Pagerfanta(new DoctrineORMAdapter($query));
$paginator = new Pagerfanta(new DoctrineORMAdapter($query, false));
$paginator->setMaxPerPage($maxPerPage);
$paginator->setCurrentPage($page);

Expand Down

0 comments on commit 98eb5ea

Please sign in to comment.