Feature #24019
openEpic #93528: Backlog of UX ideas for Editors
Enhance IRRE to allow new records to appear at the top
0%
Description
The current implementation always adds new IRRE records after all or after an already existing record.
There are some cases, when the ordering of the list is not relevant or if you sort the records e.g. by date, the newest one should be displayed at the top.
If the list of records is very long, the only visual feedback you get is a growing scrollbar, so some people might click "Create new" several times until they realize the that something happend.
Solution: add new config option "newRecordPosition" in the appearance section
prototype already has actions to make a "Insertion.Top", so the only big change is to let IRRE use that function and reorder the list of records right.
How to test:
- install the extension "irre_tutorial" and import the sample t3d to get something to work on
- add this to your extTables.php to create all new relations at the top:
t3lib_div::loadTCA('tx_irretutorial_1ncsv_hotel');
t3lib_div::loadTCA('tx_irretutorial_1nff_hotel');
t3lib_div::loadTCA('tx_irretutorial_mnasym_hotel');
t3lib_div::loadTCA('tx_irretutorial_mnattr_hotel');
t3lib_div::loadTCA('tx_irretutorial_mnmmasym_hotel');
t3lib_div::loadTCA('tx_irretutorial_mnsym_hotel');
$GLOBALS['TCA']['tx_irretutorial_1ncsv_hotel']['columns']['offers']['config']['appearance']['newRecordPosition'] = 'top';
$GLOBALS['TCA']['tx_irretutorial_1nff_hotel']['columns']['offers']['config']['appearance']['newRecordPosition'] = 'top';
$GLOBALS['TCA']['tx_irretutorial_mnasym_hotel']['columns']['offers']['config']['appearance']['newRecordPosition'] = 'top';
$GLOBALS['TCA']['tx_irretutorial_mnattr_hotel']['columns']['offers']['config']['appearance']['newRecordPosition'] = 'top';
$GLOBALS['TCA']['tx_irretutorial_mnmmasym_hotel']['columns']['offers']['config']['appearance']['newRecordPosition'] = 'top';
$GLOBALS['TCA']['tx_irretutorial_mnsym_hotel']['columns']['branches']['config']['appearance']['newRecordPosition'] = 'top';
If you want to check one level deeper, you can add something like this:
$GLOBALS['TCA']['tx_irretutorial_1ncsv_offer']['columns']['prices']['config']['appearance']['newRecordPosition'] = 'top';
Note: there will be an error on saving records on the page "m:n asymmetric combo", but this has nothing do to with the patch.
See http://bugs.typo3.org/view.php?id=15996 for that.
For the pending documentation: === doc_core_api (4.5) ===
Chapter: Table Configuration Array, $TCA
Part: ['columns'][fieldname]['config'] / TYPE: "inline"
Field: appeareance:
newRecordPosition (string)
Values: 'top', 'bottom' - default: 'bottom'
Defines where the new record is inserted in the list of records.
(issue imported from #M16350)
Files