diff --git a/Classes/Controller/ListByCategoryController.php b/Classes/Controller/ListByCategoryController.php index afaa2f041e7a8b050d3f368ead53ab890a32f71b..9a5d65e2e593d045c6ec181be7de0d03f8593c0e 100644 --- a/Classes/Controller/ListByCategoryController.php +++ b/Classes/Controller/ListByCategoryController.php @@ -56,12 +56,11 @@ class ListByCategoryController extends AbstractController { * Renders the news list of a category * * @param array $newsMetaData - * @param array $newsFilter * @return void * @throws \InvalidArgumentException * @throws \TYPO3\CMS\Extbase\Persistence\Exception\InvalidQueryException */ - public function indexAction(array $newsMetaData = [], array $newsFilter = []) { + public function indexAction(array $newsMetaData = []) { $filterByCategories = FALSE; $categoryUids = GeneralUtility::intExplode(',', $this->settings['categories']); $tagUids = GeneralUtility::intExplode(',', $this->settings['tags'], TRUE); @@ -72,19 +71,10 @@ class ListByCategoryController extends AbstractController { } } - // remember selection of the filter values - $selectedTag = $this->tagRepository->findByUid((int) $newsFilter['tag']); - $selectedCategory = $this->categoryRepository->findByUid((int) $newsFilter['category']); - $this->view->assign('selectedTag', $selectedTag); - $this->view->assign('selectedCategory', $selectedCategory); - if (!$filterByCategories) { $categoryUids = [(int) $GLOBALS['TSFE']->id]; } - $tags = $this->tagRepository->findAll()->toArray(); - $this->view->assign('tags', $tags); - $categories = []; foreach ($categoryUids as $categoryUid) { $categories[$categoryUid] = $this->categoryRepository->findByUid($categoryUid); @@ -127,7 +117,7 @@ class ListByCategoryController extends AbstractController { $nextPage = $currentPageBrowserPage + 1; if ($nextPage <= $numberOfPages) { GeneralUtility::_GETset(['tx_sgnews_pagebrowser' => ['currentPage' => $nextPage]]); - $this->indexAction($newsMetaData, $newsFilter); + $this->indexAction($newsMetaData); return; } }