From 4aef0ac9a99fefae09c57289c5437d30f7ad56bc Mon Sep 17 00:00:00 2001 From: Kevin Ditscheid <kevin.ditscheid@sgalinski.de> Date: Fri, 12 Jan 2024 16:11:33 +0100 Subject: [PATCH] Revert "[BUGFIX] Fix joblist pagination for currentPage=0" This reverts commit eb952e23cf5a2a2d780581ee14bfb9d18d256658. --- Classes/Controller/JoblistController.php | 2 +- Configuration/Routes/config.yaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Classes/Controller/JoblistController.php b/Classes/Controller/JoblistController.php index 0921a150..483c525b 100644 --- a/Classes/Controller/JoblistController.php +++ b/Classes/Controller/JoblistController.php @@ -304,7 +304,7 @@ class JoblistController extends ActionController { // get all jobs for the current page $allJobsCount = $this->jobRepository->findJobsByFilter($filters)->count(); $numberOfPages = (int) ($jobLimit <= 0 ? 0 : \ceil($allJobsCount / $jobLimit)); - if ($numberOfPages !== 0 && $currentPageBrowserPage > $numberOfPages) { + if ($numberOfPages !== 0 && $currentPageBrowserPage >= $numberOfPages) { /** @var PageRenderer $pageRenderer */ $pageRenderer = GeneralUtility::makeInstance(PageRenderer::class); // the PageRenderer contains the content of the current request, the result of the following sub-request will diff --git a/Configuration/Routes/config.yaml b/Configuration/Routes/config.yaml index ba92b73c..07d771be 100644 --- a/Configuration/Routes/config.yaml +++ b/Configuration/Routes/config.yaml @@ -12,7 +12,7 @@ routeEnhancers: value: seite-jobs currentPage: type: StaticRangeMapper - start: '0' + start: '1' end: '100' defaults: currentPage: '0' -- GitLab