Skip to content

Commit 5e8e4b1

Browse files
committed
Fix new dashboard v.2 / With BoxCount & UserCount
1 parent 4e7d169 commit 5e8e4b1

File tree

2 files changed

+32
-54
lines changed

2 files changed

+32
-54
lines changed

.idea/workspace.xml

Lines changed: 30 additions & 52 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/Controller/Admin/AdminController.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,8 @@ public function dashboard()
1818
$boxRepository = $em->getRepository(Box::class);
1919
$userRepository = $em->getRepository(User::class);
2020
return $this->render('admin/dashboard.html.twig', [
21-
'boxCount' => $boxRepository->findAll(),
22-
'userCount' => $userRepository->findAll()
21+
'boxCount' => count($boxRepository->findAll()),
22+
'userCount' => count($userRepository->findAll())
2323
]);
2424
}
2525
}

0 commit comments

Comments
 (0)