mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-02-04 20:40:14 +01:00
Calendar: Sort similar length all day events alphabetically
This commit is contained in:
parent
5477f3d095
commit
bd507ca1a3
@ -728,7 +728,7 @@ var et2_calendar_daycol = /** @class */ (function (_super) {
|
||||
// Longer duration comes first so we have nicer bars across the top
|
||||
var duration = (new Date(b.options.value.end) - new Date(b.options.value.start)) -
|
||||
(new Date(a.options.value.end) - new Date(a.options.value.start));
|
||||
return duration ? duration : (a.options.value.app_id - b.options.value.app_id);
|
||||
return (Math.abs(duration) > 360000) ? duration : (a.options.value.title.localeCompare(b.options.value.title));
|
||||
}
|
||||
else if (a.options.value.whole_day || b.options.value.whole_day) {
|
||||
return a.options.value.whole_day ? -1 : 1;
|
||||
|
@ -921,7 +921,7 @@ export class et2_calendar_daycol extends et2_valueWidget implements et2_IDetache
|
||||
(new Date(b.options.value.end) - new Date(b.options.value.start)) -
|
||||
(new Date(a.options.value.end) - new Date(a.options.value.start));
|
||||
|
||||
return duration ? duration : (a.options.value.app_id - b.options.value.app_id);
|
||||
return (Math.abs(duration) > 360000) ? duration : (a.options.value.title.localeCompare(b.options.value.title));
|
||||
}
|
||||
else if (a.options.value.whole_day || b.options.value.whole_day)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user