-
Notifications
You must be signed in to change notification settings - Fork 21
Open
Description
Here it converts the javascript "Date" object into the untis format as string:
Lines 803 to 814 in 51576aa
| /** | |
| * Convert a JS Date Object to a WebUntis date string | |
| * @param {Date} date | |
| * @returns {String} | |
| */ | |
| static convertDateToUntis(date: Date): string { | |
| return ( | |
| date.getFullYear().toString() + | |
| (date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1).toString() + | |
| (date.getDate() < 10 ? '0' + date.getDate() : date.getDate()).toString() | |
| ); | |
| } |
"Date" in javascript uses the local time, not utc. Afaik, I haven't seen a timezone being transmitted to webuntis.
Is the timezone assuming utc or is the timezone set by the school?
Metadata
Metadata
Assignees
Labels
No labels