diff --git a/src/app/reminder-plugin/reminder.model.ts b/src/app/reminder-plugin/reminder.model.ts index ec688ef..96210b1 100644 --- a/src/app/reminder-plugin/reminder.model.ts +++ b/src/app/reminder-plugin/reminder.model.ts @@ -25,6 +25,7 @@ export interface Reminder extends IEvent { status: ReminderStatus; isGroup?: object; diff?: number; + isCleared?: object; } export interface ReminderGroup { diff --git a/src/app/reminder-plugin/services/reminder.service.ts b/src/app/reminder-plugin/services/reminder.service.ts index d7bf5be..74676bb 100644 --- a/src/app/reminder-plugin/services/reminder.service.ts +++ b/src/app/reminder-plugin/services/reminder.service.ts @@ -125,6 +125,9 @@ export class ReminderService { status: reminder.status, }; + // (un)set `isCleared` fragment to supoprt using retention rules for cleared reminders + event.isCleared = (reminder.status === ReminderStatus.cleared) ? {} : null; + return (await this.eventService.update(event)) as IResult; }