5688-worker.calendar_workCenter #1580

Merged
vicent merged 11 commits from 5688-worker.calendar_workCenter into dev 2023-06-28 11:38:50 +00:00
2 changed files with 2 additions and 6 deletions
Showing only changes of commit 55990869e2 - Show all commits

View File

@ -293,6 +293,5 @@
"Pass expired": "La contraseña ha caducado, cambiela desde Salix",
"Invalid NIF for VIES": "Invalid NIF for VIES",
"Ticket does not exist": "Este ticket no existe",
"Ticket is already signed": "Este ticket ya ha sido firmado",
"This worker does not have a work center": "Este trabajador no tiene centro de trabajo"
"Ticket is already signed": "Este ticket ya ha sido firmado"
}

View File

@ -117,10 +117,7 @@ module.exports = Self => {
absences.push(absence);
}
const workCenter = contract.workCenter();
if (!workCenter) throw new UserError(`This worker does not have a work center`);
for (let day of workCenter.holidays()) {
for (let day of contract.workCenter().holidays()) {
day.dated = new Date(day.dated);
day.dated.setHours(0, 0, 0, 0);