diff --git a/modules/worker/front/calendar/index.js b/modules/worker/front/calendar/index.js index 92bad1f0f..9072f5149 100644 --- a/modules/worker/front/calendar/index.js +++ b/modules/worker/front/calendar/index.js @@ -198,7 +198,7 @@ class Controller extends Section { const event = this.events[stamp]; const calendar = $event.target.closest('vn-calendar').$ctrl; - if (event) { + if (event && event.absenceId) { if (event.type == this.absenceType.code) this.delete(calendar, day, event); else @@ -228,6 +228,7 @@ class Controller extends Section { this.repaintCanceller(() => this.refresh() .then(calendar.repaint()) + .then(() => this.repaint()) .then(() => this.getContractHolidays()) .then(() => this.getYearHolidays()) ); @@ -264,6 +265,7 @@ class Controller extends Section { this.repaintCanceller(() => this.refresh() .then(calendar.repaint()) + .then(() => this.repaint()) .then(() => this.getContractHolidays()) .then(() => this.getYearHolidays()) );