{{ 'addon.calendar.reminders' | translate }}
diff --git a/src/addons/calendar/pages/edit-event/edit-event.page.ts b/src/addons/calendar/pages/edit-event/edit-event.page.ts index b76cc4f96..79190818a 100644 --- a/src/addons/calendar/pages/edit-event/edit-event.page.ts +++ b/src/addons/calendar/pages/edit-event/edit-event.page.ts @@ -33,7 +33,7 @@ import { AddonCalendarSubmitCreateUpdateFormDataWSParams, } from '../../services/calendar'; import { AddonCalendarOffline } from '../../services/calendar-offline'; -import { AddonCalendarEventReminder, AddonCalendarEventTypeOption, AddonCalendarHelper } from '../../services/calendar-helper'; +import { AddonCalendarEventTypeOption, AddonCalendarHelper } from '../../services/calendar-helper'; import { AddonCalendarSync, AddonCalendarSyncProvider } from '../../services/calendar-sync'; import { CoreSite } from '@classes/site'; import { Translate } from '@singletons'; @@ -43,8 +43,8 @@ import { CoreError } from '@classes/errors/error'; import { CoreNavigator } from '@services/navigator'; import { CanLeave } from '@guards/can-leave'; import { CoreForms } from '@singletons/form'; -import { CoreLocalNotifications } from '@services/local-notifications'; -import { AddonCalendarReminderTimeModalComponent } from '@addons/calendar/components/reminder-time-modal/reminder-time-modal'; +import { CoreReminders, CoreRemindersService, CoreRemindersUnits } from '@features/reminders/services/reminders'; +import { CoreRemindersSetReminderMenuComponent } from '@features/reminders/components/set-reminder-menu/set-reminder-menu'; /** * Page that displays a form to create/edit an event. @@ -85,7 +85,7 @@ export class AddonCalendarEditEventPage implements OnInit, OnDestroy, CanLeave { descriptionControl: FormControl; // Reminders. - notificationsEnabled = false; + remindersEnabled = false; reminders: AddonCalendarEventCandidateReminder[] = []; protected courseId!: number; @@ -100,7 +100,7 @@ export class AddonCalendarEditEventPage implements OnInit, OnDestroy, CanLeave { protected fb: FormBuilder, ) { this.currentSite = CoreSites.getRequiredCurrentSite(); - this.notificationsEnabled = CoreLocalNotifications.isAvailable(); + this.remindersEnabled = CoreReminders.isEnabled(); this.errors = { required: Translate.instant('core.required'), }; @@ -133,7 +133,7 @@ export class AddonCalendarEditEventPage implements OnInit, OnDestroy, CanLeave { } /** - * Component being initialized. + * @inheritdoc */ ngOnInit(): void { this.eventId = CoreNavigator.getRouteNumberParam('eventId') || undefined; @@ -156,7 +156,6 @@ export class AddonCalendarEditEventPage implements OnInit, OnDestroy, CanLeave { /** * Fetch the data needed to render the form. * - * @param refresh Whether it's refreshing data. * @return Promise resolved when done. */ protected async fetchData(): Promise{{ reminder.label }}
{{ reminder.sublabel }}
-
+ {{ date.label }} - {{ date.readableTime }} --
+ {{ date.label }} - {{ date.readableTime }} -
-
- {{ course.startdate * 1000 | coreFormatDate:'strftimedaydatetime' }}
-
-
- {{ course.enddate * 1000 | coreFormatDate:'strftimedaydatetime' }}
-
{{ option.label }}
+{{ 'core.reminders.custom' | translate }}
+{{ customLabel }}
+{{ noReminderLabel | translate }}
+