mirror of
https://github.com/moodle/moodle.git
synced 2025-03-21 16:10:15 +01:00
Merge branch 'MDL-48088-master' of git://github.com/jethac/moodle
This commit is contained in:
commit
0a6ac6e2d9
@ -1931,6 +1931,9 @@ function calendar_normalize_tz($tz) {
|
||||
case('Japan Standard Time'):
|
||||
$tz = 'Asia/Tokyo';
|
||||
break;
|
||||
case('Romance Standard Time'):
|
||||
$tz = 'Europe/Brussels';
|
||||
break;
|
||||
}
|
||||
return $tz;
|
||||
}
|
||||
@ -2971,6 +2974,7 @@ function calendar_add_icalendar_event($event, $courseid, $subscriptionid, $timez
|
||||
} else {
|
||||
$endtz = isset($event->properties['DTEND'][0]->parameters['TZID']) ? $event->properties['DTEND'][0]->parameters['TZID'] :
|
||||
$timezone;
|
||||
$endtz = calendar_normalize_tz($endtz);
|
||||
$eventrecord->timeduration = strtotime($event->properties['DTEND'][0]->value . ' ' . $endtz) - $eventrecord->timestart;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user