Open biddana2 opened 3 years ago
Hi @richardhand @vladbailescu, do we wait for someone to pick these up?
hi @biddana2, theOrder By
field Created
is based on when the CF is created as you said, so the date gets 'reset' once the CF's get published and recreated on the publish instance. So a better naming would maybe be 'published Date'.
What you are looking for is date that is stored as part of your CF. So you would have to add a date field to your content fragment model and sort by that one. Unfortunately the current implementation only allows for ordering by string fields.
There has been a feature request for this see #1078, which also describes a workaround to be able to sort by date.
Bug Report
Current Behavior When using a Content Fragment List, and ordering by 'Created', shows the correct order in Author instance. But on Publish instance, it shows the order in which the CFs were published, not when they were created on author.
Expected behavior/code The order of CFs in the CF List should be the same in Author and Publish instances.
Author:
Publish:
CF List Ordered by 'Created'
The workaround for this is to unpublish the CFs under the path, and publish them in the order you want them to show. But the CF List order by 'created' should use the 'created' date from author.
Expected behavior/code The order of CFs in the CF List should be the same in Author and Publish instances.
Environment
AEM 6.5.7
2.12.0
Java(TM) SE Runtime Environment (build 1.8.0_152-b16)
Additional context / Screenshots This can be re-created on a vanilla instance.