mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-07 16:44:07 +01:00
* eSync/Calendar: fixed tz-aliases to NOT use Etc/GMT* but Olson identifiers, no more exception in AS tzblob generation, generation of tzblobs for Etc/GMT*
This commit is contained in:
parent
73c1ae8617
commit
8d61fc86a3
@ -1328,7 +1328,18 @@ END:VTIMEZONE
|
||||
|
||||
if (!isset($standard))
|
||||
{
|
||||
throw new egw_exception_assertion_failed("NO standard component for '$name' in '$component'!");
|
||||
if (preg_match('/^etc\/gmt([+-])([0-9]+)$/i',$name,$matches))
|
||||
{
|
||||
$standard = array(
|
||||
'TZOFFSETTO' => sprintf('%s%02d00',$matches[1],$matches[2]),
|
||||
'TZOFFSETFROM' => sprintf('%s%02d00',$matches[1],$matches[2]),
|
||||
);
|
||||
unset($daylight);
|
||||
}
|
||||
else
|
||||
{
|
||||
throw new egw_exception_assertion_failed("NO standard component for '$name' in '$component'!");
|
||||
}
|
||||
}
|
||||
// get bias and dstbias from standard component, which is present in all tz's
|
||||
// (dstbias is relative to bias and almost always 60 or 0)
|
||||
@ -1482,10 +1493,15 @@ END:VTIMEZONE
|
||||
error_log(__METHOD__.'('.array2string($data).') NO matching timezone found --> using UTC now!');
|
||||
break;
|
||||
}
|
||||
if (self::tz2as($tz) == $data)
|
||||
{
|
||||
$cache[$key] = $tz;
|
||||
break;
|
||||
try {
|
||||
if (self::tz2as($tz) == $data)
|
||||
{
|
||||
$cache[$key] = $tz;
|
||||
break;
|
||||
}
|
||||
}
|
||||
catch(Exception $e) {
|
||||
// simpy ignore that, as it only means $tz can NOT be converted, because it has no VTIMEZONE component
|
||||
}
|
||||
}
|
||||
return $cache[$key];
|
||||
@ -1600,6 +1616,7 @@ if (isset($_SERVER['SCRIPT_FILENAME']) && $_SERVER['SCRIPT_FILENAME'] == __FILE_
|
||||
'America/New_York' => 'LAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAsAAAABAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAMAAAACAAMAAAAAAAAAxP///w==',
|
||||
'Pacific/Auckland' => 'MP3//wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAQAAAABAAIAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAkAAAAFAAMAAAAAAAAAxP///w==',
|
||||
'Australia/Sydney' => 'qP3//wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAMAAAAFAAMAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAoAAAAFAAIAAAAAAAAAxP///w==',
|
||||
'Etc/GMT+3' => 'TP///wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA==',
|
||||
) as $tz => $sync_blob)
|
||||
{
|
||||
// get as timezone data for a given timezone
|
||||
|
@ -48,7 +48,7 @@ $tz_aliases = array(
|
||||
'Fiji Standard Time' => 'Pacific/Fiji',
|
||||
'GMT Standard Time' => 'Europe/London',
|
||||
'GTB Standard Time' => 'Europe/Istanbul',
|
||||
'Georgian Standard Time' => 'Etc/GMT-3',
|
||||
'Georgian Standard Time' => 'Asia/Tbilisi',
|
||||
'Greenland Standard Time' => 'America/Godthab',
|
||||
'Greenwich Standard Time' => 'Atlantic/Reykjavik', // was 'Africa/Reykjavik',
|
||||
'Hawaiian Standard Time' => 'Pacific/Honolulu',
|
||||
@ -80,7 +80,7 @@ $tz_aliases = array(
|
||||
'Pakistan Standard Time' => 'Asia/Karachi',
|
||||
'Romance Standard Time' => 'Europe/Paris',
|
||||
'Russian Standard Time' => 'Europe/Moscow',
|
||||
'SA Eastern Standard Time' => 'Etc/GMT+3',
|
||||
'SA Eastern Standard Time' => 'America/Buenos_Aires',
|
||||
'SA Pacific Standard Time' => 'America/Bogota',
|
||||
'SA Western Standard Time' => 'America/La_Paz',
|
||||
'SE Asia Standard Time' => 'Asia/Bangkok',
|
||||
@ -92,7 +92,7 @@ $tz_aliases = array(
|
||||
'Tasmania Standard Time' => 'Australia/Hobart',
|
||||
'Tokyo Standard Time' => 'Asia/Tokyo',
|
||||
'Tonga Standard Time' => 'Pacific/Tongatapu',
|
||||
'US Eastern Standard Time' => 'Etc/GMT+5',
|
||||
'US Eastern Standard Time' => 'America/New_York',
|
||||
'US Mountain Standard Time' => 'America/Phoenix',
|
||||
'Venezuela Standard Time' => 'America/Caracas',
|
||||
'Vladivostok Standard Time' => 'Asia/Vladivostok',
|
||||
|
Loading…
Reference in New Issue
Block a user