Query crutchy fix.

This commit is contained in:
Alexey Skobkin 2015-06-23 14:19:57 +03:00
parent aedc15a204
commit 5778404813
1 changed files with 2 additions and 1 deletions

View File

@ -67,7 +67,8 @@ class UserRepository extends EntityRepository
throw new \InvalidArgumentException('$limit must be an integer');
}
$qb = $this->createQueryBuilder('s');
// TODO: refactor query
$qb = $this->getEntityManager()->getRepository('SkobkinPointToolsBundle:Subscription')->createQueryBuilder('s');
return $qb
->select(['COUNT(s.subscriber) as cnt', 'NEW SkobkinPointToolsBundle:TopUserDTO(a.login, COUNT(s.subscriber))'])