Feature #64197
closedAdd support for foreign_default_sortby on TCA inline fields
100%
Description
The origin issue has been closed (see below). But shouldn't this feature be implemented at all? I've seen several posts across the internet from people missing this feature...
--- Original issue ---
Issue #50439 has been updated by Alexander Opitz.
Status changed from Needs Feedback to Closed
No feedback within the last 90 days => closing this ticket.
If you think that this is the wrong decision or experience this issue again, then please write to the mailing list typo3.teams.bugs with issue number and an explanation or open a new ticket and add a relation to this ticket number.
----------------------------------------
Feature #50439: Reopened: Add support for foreign_default_sortby on TCA inline fields
http://forge.typo3.org/issues/50439#change-243018
Author: Jan Kornblum
Status: Closed
Priority: Should have
Assigned To:
Category: Extbase
Target version:
Has patch: No
Tags:
Complexity:
Persistence needs support for sorting child records by foreign_default_sortby, see http://typo3.org/documentation/document-library/core-documentation/doc_core_api/4.2.0/view/4/2/#id4431730
Won't this be implemented at all? Without the possibility of sorting children (object storage) nearly each domain model needs to be an aggregate root!?
Imagine you would like to output the following list in fluid (categories <1:n> seminars <1:n> events, where the children are lazy object storages in the parent):
- Categories (Alphabetical)
--- Seminars (Alphabetical)
------ Events (By date)
Currently this seems only to be possible by using something like FED DataSortViewHelper. The "usort" method in the model didn't work in my case because of some boolean issues i didn't figure out.
Is there really no possibility to extend extbase to respect a TCA "foreign_default_sortby" annotation?
Files
Updated by Jan Kornblum over 9 years ago
Am i wrong with my assumption that the core guys don't like to implement the feature to sorting (child) objectstorages on creation or that this is not really easy to accomplish (i've got this feeling by reading other issues)?
I've just recognized that other frameworks (e.g. like .net entity framework) don't offer the possibility to sort child objects on creation, too. But they usually offer the possibility to sort children in the views.
So an alternative would be, to integrate a sort-viewhelper directly into the core.
Updated by Mathias Schreiber about 9 years ago
- Target version deleted (
next-patchlevel)
Updated by Gerrit Code Review over 5 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/c/Packages/TYPO3.CMS/+/61487
Updated by Pascal Rinker over 5 years ago
- Related to Bug #27659: sorting by $TCA foreign_sortby vs. foreign_default_sortby added
Updated by Gerrit Code Review over 5 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/c/Packages/TYPO3.CMS/+/61487
Updated by Gerrit Code Review over 5 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/c/Packages/TYPO3.CMS/+/61487
Updated by Gerrit Code Review over 5 years ago
Patch set 4 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/61487
Updated by Pascal Rinker over 5 years ago
- Target version set to Candidate for Major Version
Updated by Gerrit Code Review over 5 years ago
Patch set 5 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/61487
Updated by Gerrit Code Review about 5 years ago
Patch set 6 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/61487
Updated by Gerrit Code Review about 5 years ago
Patch set 7 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/61487
Updated by Rainer Becker about 4 years ago
Any news on this? In TYPO3 10.4.9 the field used in foreign_sortby is still hidden from IRRE editing like described in the original ticket https://forge.typo3.org/issues/27659#note-1.
Updated by JAKOTA Design Group GmbH over 2 years ago
Hi,
Any news on this one?
I was facing the same problem in 11.5.x and applying this patch solved it.
I only simplified the patch a bit:
typo3/sysext/extbase/Classes/Persistence/Generic/Mapper/DataMapFactory.php
in protected function setOneToOneRelation(ColumnMap $columnMap, array $columnConfiguration = null): ColumnMap
$columnMap->setChildSortByFieldName($columnConfiguration['foreign_sortby'] ?? null); to $columnMap->setChildSortByFieldName($columnConfiguration['foreign_sortby'] ?? $columnConfiguration['foreign_default_sortby'] ?? null);
and protected function setOneToManyRelation(ColumnMap $columnMap, array $columnConfiguration = null): ColumnMap
$columnMap->setChildSortByFieldName($columnConfiguration['foreign_sortby'] ?? null); to $columnMap->setChildSortByFieldName($columnConfiguration['foreign_sortby'] ?? $columnConfiguration['foreign_default_sortby'] ?? null);
Updated by JAKOTA Design Group GmbH over 1 year ago
Hi,
I've updated the fix from https://review.typo3.org/c/Packages/TYPO3.CMS/+/61487 and solved (so I hope) the issue Alexander Schnitzler mentioned in his last comment.
This Patch file is against main and I've tested it with 11.5.24.
Updated by Gerrit Code Review over 1 year ago
Patch set 1 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/77985
Updated by Gerrit Code Review over 1 year ago
Patch set 2 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/77985
Updated by Gerrit Code Review over 1 year ago
Patch set 3 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/77985
Updated by Gerrit Code Review over 1 year ago
Patch set 4 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/77985
Updated by Gerrit Code Review over 1 year ago
Patch set 5 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/77985
Updated by Gerrit Code Review over 1 year ago
Patch set 6 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/77985
Updated by Gerrit Code Review over 1 year ago
Patch set 7 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/77985
Updated by Jan Kornblum over 1 year ago
JAKOTA Design Group GmbH wrote in #note-14:
Hi,
I've updated the fix from https://review.typo3.org/c/Packages/TYPO3.CMS/+/61487 and solved (so I hope) the issue Alexander Schnitzler mentioned in his last comment.
This Patch file is against main and I've tested it with 11.5.24.
Thx for fixing this! :)
Updated by Gerrit Code Review over 1 year ago
Patch set 8 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/77985
Updated by Gerrit Code Review over 1 year ago
Patch set 9 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/77985
Updated by JAKOTA Design Group GmbH over 1 year ago
Jan Kornblum wrote in #note-22:
Thx for fixing this! :)
Sure, I hope this gets approved, so I can get rid of my copy of the extbase extension which I have to rebase every month when a new version comes out.
So fixing this has more of selfish reason. ;)
Updated by Jan Kornblum over 1 year ago
JAKOTA Design Group GmbH wrote in #note-25:
Sure, I hope this gets approved, so I can get rid of my copy of the extbase extension which I have to rebase every month when a new version comes out.
So fixing this has more of selfish reason. ;)
What about https://forge.typo3.org/issues/88833 - coincidentally interested in fixing this, too? ;)
A similar issue, something essentially, missing since years although not such a "big thing" (i carefully suppose).
Updated by JAKOTA Design Group GmbH over 1 year ago
Maybe, but let's not get ahead of ourselves. I haven't even noticed that issue.
Updated by Gerrit Code Review over 1 year ago
Patch set 10 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/77985
Updated by Gerrit Code Review over 1 year ago
Patch set 11 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/77985
Updated by Gerrit Code Review over 1 year ago
Patch set 12 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/77985
Updated by Gerrit Code Review over 1 year ago
Patch set 13 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/77985
Updated by Gerrit Code Review over 1 year ago
Patch set 14 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/77985
Updated by Gerrit Code Review over 1 year ago
Patch set 15 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/77985
Updated by Gerrit Code Review over 1 year ago
Patch set 1 for branch 11.5 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/77971
Updated by Anonymous over 1 year ago
- Status changed from Under Review to Resolved
- % Done changed from 0 to 100
Applied in changeset 763c315545a12cc583c9614ad3404650dbc73749.
Updated by Gerrit Code Review over 1 year ago
- Status changed from Resolved to Under Review
Patch set 2 for branch 11.5 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/77971
Updated by Gerrit Code Review over 1 year ago
Patch set 3 for branch 11.5 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/77971
Updated by Gerrit Code Review over 1 year ago
Patch set 4 for branch 11.5 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/77971
Updated by Gerrit Code Review over 1 year ago
Patch set 5 for branch 11.5 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/77971
Updated by Anonymous over 1 year ago
- Status changed from Under Review to Resolved
Applied in changeset 30a93ac88a85066ee12c2730dd9d74847ee252a1.