fix(worker_calendar): absence in holiday day
gitea/salix/pipeline/head There was a failure building this commit Details

This commit is contained in:
Alex Moreno 2022-03-23 13:06:17 +01:00
parent b8910e38ea
commit 0963b66560
1 changed files with 3 additions and 1 deletions

View File

@ -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())
);