do not filter out empty reminders at importing events from .ics
This commit is contained in:
parent
5ff520c93d
commit
15053ef67c
|
@ -160,8 +160,8 @@ class IcsImporter(val activity: SimpleActivity) {
|
||||||
Reminder(curReminderMinutes.getOrElse(1) { REMINDER_OFF }, curReminderActions.getOrElse(1) { REMINDER_NOTIFICATION }),
|
Reminder(curReminderMinutes.getOrElse(1) { REMINDER_OFF }, curReminderActions.getOrElse(1) { REMINDER_NOTIFICATION }),
|
||||||
Reminder(curReminderMinutes.getOrElse(2) { REMINDER_OFF }, curReminderActions.getOrElse(2) { REMINDER_NOTIFICATION })
|
Reminder(curReminderMinutes.getOrElse(2) { REMINDER_OFF }, curReminderActions.getOrElse(2) { REMINDER_NOTIFICATION })
|
||||||
)
|
)
|
||||||
reminders = reminders.filter { it.minutes != REMINDER_OFF }.sortedBy { it.minutes }.toMutableList() as ArrayList<Reminder>
|
|
||||||
|
|
||||||
|
reminders = reminders.sortedBy { it.minutes }.toMutableList() as ArrayList<Reminder>
|
||||||
val eventType = eventTypes.firstOrNull { it.id == curEventTypeId }
|
val eventType = eventTypes.firstOrNull { it.id == curEventTypeId }
|
||||||
val source = if (calDAVCalendarId == 0 || eventType?.isSyncedEventType() == false) SOURCE_IMPORTED_ICS else "$CALDAV-$calDAVCalendarId"
|
val source = if (calDAVCalendarId == 0 || eventType?.isSyncedEventType() == false) SOURCE_IMPORTED_ICS else "$CALDAV-$calDAVCalendarId"
|
||||||
val event = Event(null, curStart, curEnd, curTitle, curLocation, curDescription, reminders[0].minutes,
|
val event = Event(null, curStart, curEnd, curTitle, curLocation, curDescription, reminders[0].minutes,
|
||||||
|
|
Loading…
Reference in New Issue