mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-07 17:49:17 +00:00
When two events are on at exactly the same time, sort the first to be created earlier in the list (helps keep order, and makes tests simpler)
git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@30181 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -255,9 +255,11 @@ public class CalendarServiceImpl implements CalendarService
|
||||
}
|
||||
|
||||
// Build our sorting, by date
|
||||
// Sort by start date, then end date, then created at for two events with matching times
|
||||
List<Pair<QName,Boolean>> sort = new ArrayList<Pair<QName, Boolean>>();
|
||||
sort.add(new Pair<QName, Boolean>(CalendarModel.PROP_FROM_DATE, true));
|
||||
sort.add(new Pair<QName, Boolean>(CalendarModel.PROP_TO_DATE, true));
|
||||
sort.add(new Pair<QName, Boolean>(ContentModel.PROP_CREATED, true));
|
||||
|
||||
// We only want calendar entries
|
||||
Set<QName> types = new HashSet<QName>();
|
||||
|
Reference in New Issue
Block a user