Add limit param to all endpoints

This commit is contained in:
James Cole
2023-10-05 18:52:01 +02:00
parent a29d056a9b
commit 664a08d42f
46 changed files with 136 additions and 138 deletions

View File

@@ -77,7 +77,7 @@ class ListController extends Controller
{
$manager = $this->getManager();
$pageSize = (int)app('preferences')->getForUser(auth()->user(), 'listPageSize', 50)->data;
$pageSize = $this->parameters->get('limit');
// get list of piggy banks. Count it and split it.
$collection = $this->repository->getBills($objectGroup);
$count = $collection->count();
@@ -114,7 +114,7 @@ class ListController extends Controller
$manager = $this->getManager();
// types to get, page size:
$pageSize = (int)app('preferences')->getForUser(auth()->user(), 'listPageSize', 50)->data;
$pageSize = $this->parameters->get('limit');
// get list of piggy banks. Count it and split it.
$collection = $this->repository->getPiggyBanks($objectGroup);

View File

@@ -79,7 +79,7 @@ class ShowController extends Controller
$manager = $this->getManager();
// types to get, page size:
$pageSize = (int)app('preferences')->getForUser(auth()->user(), 'listPageSize', 50)->data;
$pageSize = $this->parameters->get('limit');
$this->repository->resetOrder();
$collection = $this->repository->get();