Skip to content

Commit

Permalink
Merge pull request #793 from biedert/issue/791
Browse files Browse the repository at this point in the history
Switch to SlidingWindowPagination in Frontend List
  • Loading branch information
lochmueller authored Mar 4, 2024
2 parents 4837c86 + 38ff4c1 commit 4d1769d
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
1 change: 1 addition & 0 deletions Classes/Controller/BackendController.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
use TYPO3\CMS\Core\Localization\LanguageServiceFactory;
use TYPO3\CMS\Core\Pagination\ArrayPaginator;
use TYPO3\CMS\Core\Pagination\SimplePagination;
use TYPO3\CMS\Core\Pagination\SlidingWindowPagination;
use TYPO3\CMS\Extbase\Pagination\QueryResultPaginator;
use TYPO3\CMS\Extbase\Property\TypeConverter\DateTimeConverter;

Expand Down
4 changes: 2 additions & 2 deletions Classes/Controller/CalendarController.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
use Psr\Http\Message\ResponseInterface;
use TYPO3\CMS\Backend\Utility\BackendUtility;
use TYPO3\CMS\Core\MetaTag\MetaTagManagerRegistry;
use TYPO3\CMS\Core\Pagination\SimplePagination;
use TYPO3\CMS\Core\Pagination\SlidingWindowPagination;
use TYPO3\CMS\Core\Utility\GeneralUtility;
use TYPO3\CMS\Core\Utility\MathUtility;
use TYPO3\CMS\Extbase\Annotation as Extbase;
Expand Down Expand Up @@ -774,7 +774,7 @@ protected function getPagination(QueryResultInterface $queryResult): array
: 1;

$paginator = new QueryResultPaginator($queryResult, $currentPage, $itemsPerPage);
$pagination = new SimplePagination($paginator);
$pagination = new SlidingWindowPagination($paginator, $maximumNumberOfLinks);

$event = new PaginationEvent(
$paginator,
Expand Down
1 change: 0 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,6 @@
},
"suggest": {
"brotkrueml/schema": "Output of structured data information for better Google Search Result User Experience",
"georgringer/numbered-pagination": "Pagination with reduced amount of pages",
"typo3/cms-dashboard": "Dashboard widgets"
},
"require-dev": {
Expand Down

0 comments on commit 4d1769d

Please sign in to comment.