Bug #17876
closedSorting of child records is inverted on moving parent record to different page
0%
Description
If you want to move a IRRE record with manual sorted child records, the sorting of the child records will be inverted.
First is last, last is first and so on...
(issue imported from #M6875)
Files
Updated by Benno Weinzierl almost 16 years ago
I can confirm that on Version 4.1.7
Updated by Tobias Liebig over 15 years ago
attached small extension to reproduce the behaviour
- install extension
- go into the list module
- create a "parents" record
- add serveral "children" to the new parent record (at least 3)
- give them certain names so you can check the correct order later
- "cut" the parent record from list modul
- go to another page and paste the record
- edit it and see that the order of the children is reversed
Updated by Nabil Saleh over 15 years ago
patch added BUT i'm not shure if there are any sideeffects please test
Updated by Christian Kuhn over 15 years ago
Thanks Tobias for the test extension.
Nabil, your patch works, thanks.
I uploaded another version that doesn't use array_reverse, but some logic very similar to what was done in #16603. I don't really like the array_reverse, it just looks a bit unmotivated there. My version makes a bit better use of the given API.
So choosing v1 or v2 is a matter of taste, maybe Oliver could state his preference.
Nabil, you could choose one version and send it (together with test extension and reproduce howto) to core-list. Target branches are 4.2 and trunk.
Updated by Nabil Saleh over 15 years ago
sent to corelist. sorry for being late but bugtracker seemed to have a problem in sending mails so I haven't been informed about updates.
Thx for your patch it's indeed better in readability and maby even in logic :).
Updated by Oliver Hader over 15 years ago
The v3-patch is just educational how to use v2 without an if-block... ;-)
However, I prefer the array_reverse() patch since it does not produce that many lookups to determine the correct page ID for each child record.
Updated by Oliver Hader over 15 years ago
- TYPO3_4-2 (rev. 5724)
- Trunk (rev. 5725)