From bd23cf49fcbd80c9de75e819d47025a8720a1b0c Mon Sep 17 00:00:00 2001 From: yflory Date: Thu, 15 Apr 2021 17:48:42 +0200 Subject: [PATCH] Update reminders when importing a calendar --- www/common/outer/calendar.js | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/www/common/outer/calendar.js b/www/common/outer/calendar.js index 1bdde4724..5f39004c1 100644 --- a/www/common/outer/calendar.js +++ b/www/common/outer/calendar.js @@ -95,8 +95,6 @@ define([ var ev = Util.clone(_ev); var uid = ev.id; - //ctx.store.data.lastVisit = 1617922639683; // XXX Friday Apr 09, used to test - // Clear reminders for this event if (Array.isArray(reminders[uid])) { reminders[uid].forEach(function (to) { clearTimeout(to); }); @@ -124,11 +122,6 @@ define([ return; } - // XXX - // TODO - // use custom notifications per event - // if you missed a notification, show it instantly (eg: load cryptpad 45min before an event, show the 1h notification) - var send = function () { var hide = Util.find(ctx, ['store', 'proxy', 'settings', 'general', 'calendar', 'hideNotif']); if (hide) { return; } @@ -524,6 +517,7 @@ define([ c.proxy.content = c.proxy.content || {}; Object.keys(json).forEach(function (uid) { c.proxy.content[uid] = json[uid]; + addReminders(ctx, id, json[uid]); }); Realtime.whenRealtimeSyncs(c.lm.realtime, function () {