API works for multi-account piggies, the rest throws an exception

This commit is contained in:
James Cole
2024-12-01 18:32:05 +01:00
parent cdf1ebf3f7
commit d740814f88
8 changed files with 82 additions and 71 deletions

View File

@@ -72,7 +72,7 @@ class ShowController extends Controller
// types to get, page size:
$pageSize = $this->parameters->get('limit');
// get list of budgets. Count it and split it.
// get list of piggy banks. Count it and split it.
$collection = $this->repository->getPiggyBanks();
$count = $collection->count();
$piggyBanks = $collection->slice(($this->parameters->get('page') - 1) * $pageSize, $pageSize);