Bug #59893

Backend search box: use label_alt field value if label is emtpy

Added by Marcin Sągol over 6 years ago. Updated over 2 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
Backend User Interface
Target version:
-
Start date:
2014-06-26
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
6.2
PHP Version:
5.5
Tags:
Complexity:
Is Regression:
No
Sprint Focus:

Description

Through TCA we can configure columns that are used to display record name (for example on the records list):

$TCA['tx_foo_domain_model_bar'] = array(
    'ctrl' => array(
        'title'    => 'Some title',
        'label' => 'name',
        'label_alt' => 'name',
    ),
);

If column defined as label is empty, than label_alt is used (if defined). This works fine in the List module.
If we use backend searchbox to find records, it seems that only label is used and label_alt ignored. It would be nice if the searchbox could respect also label_alt option.


Related issues

Related to TYPO3 Core - Bug #59957: Duplicate code respectively not used variable in sysext\backend\Classes\Search\LiveSearch\LiveSearch.phpClosed2014-06-28

Actions
#1

Updated by Markus Klein over 6 years ago

Are you talking about the search box on the top right, or the one that in included in the list module?

#2

Updated by Markus Klein over 6 years ago

From what I see the label is not considered at all.
All search fields must be defined in TCA $GLOBALS['TCA'][$tableName]['ctrl']['searchFields'].

#3

Updated by Marcin Sągol over 6 years ago

Hi Markus,

yes search fields have to be configured. The question now is, what field from the table is used to display record name in search results.

#4

Updated by Markus Klein over 6 years ago

Ah alright, now I got it. It's about the result list and not how the search is performed.

#5

Updated by Marcin Sągol over 6 years ago

Yes. If we are using label_alt, on the list we can se only record type icon and no name (as label is empty and label_alt probably not considered at all).

#6

Updated by Gerrit Code Review over 6 years ago

  • Status changed from New to Under Review

Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/31197

#7

Updated by Gerrit Code Review over 6 years ago

Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/31197

#8

Updated by Gerrit Code Review over 6 years ago

Patch set 3 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/31197

#9

Updated by Gerrit Code Review over 6 years ago

Patch set 1 for branch TYPO3_6-2 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/31247

#10

Updated by Markus Klein over 6 years ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100
#11

Updated by Gerrit Code Review over 6 years ago

  • Status changed from Resolved to Under Review

Patch set 2 for branch TYPO3_6-2 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/31247

#12

Updated by Markus Klein over 6 years ago

  • Status changed from Under Review to Resolved
#13

Updated by Benni Mack over 2 years ago

  • Status changed from Resolved to Closed

Also available in: Atom PDF