Exemple #1
0
        public async Task <bool> AddAsync(Calendars.Calendar customCalendar)
        {
            await CalendarService.AddOrUpdateCalendarAsync(customCalendar);

            items.Add(customCalendar);

            return(true);
        }
Exemple #2
0
        public async Task <bool> UpdateAsync(Calendars.Calendar calendar)
        {
            await CalendarService.AddOrUpdateCalendarAsync(calendar);

            var oldItem = items.Where(c => c.ExternalID == calendar.ExternalID).Single();

            items.Remove(oldItem);
            items.Add(calendar);

            return(true);
        }