-
-
Couldn't load subscription status.
- Fork 66
Description
When pagination is enabled (in listView), and a value is set in settings.queryLimit also, the queryLimit is not used correctly.
So e.g. if I set settings.pagination.itemsPerPage = 6 and settings.queryLimit = 3 I get 6 results, but at least no more pagination links.
The expected result should be to have 3 records.
I could provide a PR, @derhansen , that takes care of settings.queryLimit in the getPagination() of AbstractController, if its value is > 0.
So basically instead of
$paginator = new QueryResultPaginator($events, $currentPage, (int)($settings['itemsPerPage'] ?? 10));
it should be
$paginator = new QueryResultPaginator($events, $currentPage, (int)($this->settings['queryLimit] ?? 10));
i guess, and it should be fine.
What do you think? Should I create the PR?