Review 12.4 Merged

82480[TASK] Sort table and field list in DB Check module by labels

Andreas Kienast CR +2 V +2 Easy +21 −13 updated 01/19/24, 12:22

Commit message

When we use DB Check module and our project has large number of
tables configured in the TCA it is often hard to quickly find on the
select list the one we are interested with.

This commit adds small changes to `DatabaseIntegrityController` to:
- sort (ASC) available tables list by table label
- if table label is not defined, use raw table name wrapped with [...]
- sort (ASC) fields defined for table by their labels
- if field label is not defined, [FIELD: xxx] is used as before

Examples for table label

$GLOBALS['TCA']['sys_file']['title'] = 'Label';
- result without debug mode enabled in the BE: 'Label'
- result with debug mode disabled in BE: 'Label [sys_file]'

$GLOBALS['TCA']['sys_file']['title'] = '';
- result without debug mode enabled in the BE: '[sys_file]'
- result with debug mode disabled in BE: '[sys_file]'

Examples for field label

$GLOBALS['TCA']['sys_file']['title']['columns']['field']['label'] = 'Label';
- result without debug mode enabled in the BE: 'Label'
- result with debug mode disabled in BE: 'Label [field]'

$GLOBALS['TCA']['sys_file']['title']['columns']['field']['label'] = '';
- result without debug mode enabled in the BE: '[FIELD: field]'
- result with debug mode disabled in BE: '[FIELD: field] [field]'

Review

  • Code review CR +2 Done
    • Andreas Kienast +2
  • Verified V +2 Done
    • Andreas Kienast +2
    • core-ci +1 CI

Issues 1

Files 1

Review log 34

  1. Andreas Kienast commented on patch set 1 01/19/24, 12:14

    Cherry Picked from branch main.
  2. core-ci voted on patch set 1 V +1 01/19/24, 12:19 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/51810

  3. Andreas Kienast voted on patch set 1 CR +2 V +2 01/19/24, 12:20

  4. Andreas Kienast merged patch set 2 01/19/24, 12:22