From c58219bf1970b4794dcd4a25cbbc5e78dedd9d2c Mon Sep 17 00:00:00 2001 From: Fabio Ventura Date: Sun, 3 Oct 2021 13:17:08 +0200 Subject: [PATCH] fix account repository --- .../src/Application/Repository/AccountRepository.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/module/Application/src/Application/Repository/AccountRepository.php b/module/Application/src/Application/Repository/AccountRepository.php index 2ca0f1f2..d6d4806e 100644 --- a/module/Application/src/Application/Repository/AccountRepository.php +++ b/module/Application/src/Application/Repository/AccountRepository.php @@ -80,11 +80,11 @@ public function getByUsage(int $userId): array $qb = $this->getEntityManager()->createQueryBuilder() ->select('a') ->from(Account::class, 'a') - ->leftJoin('a.movements', 'm') +// ->leftJoin('a.movements', 'm') ->where('a.user=:userId') ->andWhere('a.status<>:status') - ->groupBy('m.account') - ->orderBy('COUNT(m.account)', 'DESC') +// ->groupBy('m.account') +// ->orderBy('COUNT(m.account)', 'DESC') ->setParameters([':status' => Account::STATUS_CLOSED, ':userId' => $userId]); return $qb->getQuery()->getResult();