chore: added new calendars

main
Antonio De Lucreziis 2 years ago
parent 4bf696ea75
commit 9c12cbf759

2
.gitignore vendored

@ -6,3 +6,5 @@ node_modules/
.env
.env.production
.vscode/

@ -19,15 +19,34 @@ const CALENDAR_IDS = {
'anno-1': ['6308cfcb1df5cb026699ce32'],
'anno-2': ['6308e2dc09352a0208fefdd9'],
'anno-3': ['6308e42a1df5cb026699ced4'],
'magistrale': ['6308e8ea0c34e703bb1f7e85'],
'magistrale': ['63ce74397a9aee064ee01ad7'],
'tutti': [
'6308cfcb1df5cb026699ce32',
'6308e2dc09352a0208fefdd9',
'6308e42a1df5cb026699ced4',
'6308e8ea0c34e703bb1f7e85',
'63ce74397a9aee064ee01ad7',
],
}
const DATE_RANGES = {
'6308cfcb1df5cb026699ce32': {
from: '2022-10-02T22:00:00.000Z',
to: '2022-10-07T22:00:00.000Z',
},
'6308e2dc09352a0208fefdd9': {
from: '2022-10-02T22:00:00.000Z',
to: '2022-10-07T22:00:00.000Z',
},
'6308e42a1df5cb026699ced4': {
from: '2022-10-02T22:00:00.000Z',
to: '2022-10-07T22:00:00.000Z',
},
'63ce74397a9aee064ee01ad7': {
from: '2023-02-27T22:00:00.000Z',
to: '2023-03-05T22:00:00.000Z',
},
}
function specialEventPatches(eventi) {
// Il laboratorio del primo anno in realtà è in due canali separati
let i = 1
@ -60,8 +79,8 @@ async function loadEventi(ids) {
linkCalendarioId: id,
clienteId: '628de8b9b63679f193b87046',
pianificazioneTemplate: false,
dataInizio: '2022-10-02T22:00:00.000Z',
dataFine: '2022-10-07T22:00:00.000Z',
dataInizio: DATE_RANGES[id].from,
dataFine: DATE_RANGES[id].to,
}),
method: 'POST',
mode: 'cors',

Loading…
Cancel
Save