Project

General

Profile

Actions

Task #93577

closed

Epic #93528: Backlog of UX ideas for Editors

Enable the search box on sysfolders w/o any record

Added by Xavier Perseguers about 3 years ago. Updated about 3 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
-
Target version:
-
Start date:
2021-02-24
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
9
PHP Version:
Tags:
Complexity:
Sprint Focus:

Description

This problem has been reported by one of my editors, in TYPO3 v9.

Context

  • Module: Web > List

Normal Behaviour

  • Select a folder containing DB records
  • You can toggle the search box in the toolbar:

Limitation

  • Select a folder containing only subfolders but not any DB records
  • You cannot toggle the search box in the toolbar since the icon is gone!

Analysis

In \TYPO3\CMS\Recordlist\Controller\RecordListController:637 (https://github.com/TYPO3/TYPO3.CMS/blob/9.5/typo3/sysext/recordlist/Classes/Controller/RecordListController.php#L637) we have this condition to include the button in the toolbar:

if (!$this->modTSconfig['properties']['disableSearchBox'] && ($dblist->HTMLcode || !empty($dblist->searchString))) {

Since there are no DB records, TYPO3 thinks it's not worth showing the button. This is logical if you keep the Search Levels to 1 single level but if you search on 2 or more levels, then it's highly useful to keep the button since it allows for an editor to find a given record without knowing exactly where to look for it, by starting the search from some "higher level", some enclosing folder!

Suggestion

--- typo3/sysext/recordlist/Classes/Controller/RecordListController.php  2021-02-24 09:17:49.000000000 +0100
+++ typo3/sysext/recordlist/Classes/Controller/RecordListController.php  2021-02-24 09:17:49.000000000 +0100
@@ -634,7 +634,7 @@
         // Setting up the buttons for docheader
         $dblist->getDocHeaderButtons($this->moduleTemplate);
         // search box toolbar
-        if (!$this->modTSconfig['properties']['disableSearchBox'] && ($dblist->HTMLcode || !empty($dblist->searchString))) {
+        if (!$this->modTSconfig['properties']['disableSearchBox']) {
             $this->content = $dblist->getSearchBox();
             $this->moduleTemplate->getPageRenderer()->loadRequireJsModule('TYPO3/CMS/Backend/ToggleSearchToolbox');


Files

searchbox.png (12.2 KB) searchbox.png Xavier Perseguers, 2021-02-24 08:10
clipboard-202102251117-2yiuj.png (97.8 KB) clipboard-202102251117-2yiuj.png Jo Hasenau, 2021-02-25 10:17
Actions

Also available in: Atom PDF