Projects
Kolab:16:Enterprise
kolab-syncroton
Log In
Username
Password
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
Expand all
Collapse all
Changes of Revision 21
View file
kolab-syncroton.spec
Changed
@@ -36,7 +36,7 @@ %global _ap_sysconfdir %{_sysconfdir}/%{httpd_name} Name: kolab-syncroton -Version: 2.3.10 +Version: 2.3.12 Release: 1%{?dist} Summary: ActiveSync for Kolab Groupware @@ -195,6 +195,9 @@ %attr(0770,%{httpd_user},%{httpd_group}) %{_var}/log/%{name} %changelog +* Wed Jun 13 2018 Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen@kolabsys.com> - 2.3.12-1 +- Release 2.3.12 + * Thu Mar 8 2018 Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen@kolabsys.com> - 2.3.10-1 - Release 2.3.10
View file
debian.changelog
Changed
@@ -1,3 +1,9 @@ +kolab-syncroton (2.3.12-0~kolab1) unstable; urgency=low + + * Release 2.3.12 + + -- Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen@kolabsys.com> Wed, 13 Jun 2018 15:13:40 +0200 + kolab-syncroton (2.3.10-0~kolab1) unstable; urgency=low * Release 2.3.10
View file
kolab-syncroton-2.3.10.tar.gz/lib/kolab_sync.php -> kolab-syncroton-2.3.12.tar.gz/lib/kolab_sync.php
Changed
@@ -46,7 +46,7 @@ public $password; const CHARSET = 'UTF-8'; - const VERSION = "2.3.10"; + const VERSION = "2.3.12"; /** @@ -402,10 +402,14 @@ $log_dir = $this->config->get('log_dir'); $log_dir .= DIRECTORY_SEPARATOR . $this->username; - if (!$user_debug && !is_dir($log_dir)) { - if (!mkdir($log_dir, 0770)) { - return; - } + // No automatically creating any log directories. + if (!is_dir($log_dir)) { + return; + } + + // No dir, no glory + if (!mkdir($log_dir, 0770)) { + return; } if (!empty($_GET'DeviceId')) {
View file
kolab-syncroton-2.3.10.tar.gz/lib/kolab_sync_data_calendar.php -> kolab-syncroton-2.3.12.tar.gz/lib/kolab_sync_data_calendar.php
Changed
@@ -285,6 +285,9 @@ // Attendees if (!empty($event'attendees')) { + $user_emails = $this->user_emails(); + $user_rsvp = false; + foreach ($event'attendees' as $idx => $attendee) { $att = array(); @@ -298,12 +301,17 @@ $att'name' = $attendee'name' ?: $email; + $type = isset($attendee'role') ? $this->attendeeTypeMap$attendee'role' : null; + $status = isset($attendee'status') ? $this->attendeeStatusMap$attendee'status' : null; + if ($this->asversion >= 12) { - $type = isset($attendee'role') ? $this->attendeeTypeMap$attendee'role' : null; - $status = isset($attendee'status') ? $this->attendeeStatusMap$attendee'status' : null; + $att'attendeeType' = $type ?: self::ATTENDEE_TYPE_REQUIRED; + $att'attendeeStatus' = $status ?: self::ATTENDEE_STATUS_UNKNOWN; + } - $att'attendeeType' = $type ? $type : self::ATTENDEE_TYPE_REQUIRED; - $att'attendeeStatus' = $status ? $status : self::ATTENDEE_STATUS_UNKNOWN; + if ($email && in_array_nocase($email, $user_emails)) { + $user_rsvp = !empty($attendee'rsvp'); + $resp_type = $status ?: self::ATTENDEE_STATUS_UNKNOWN; } $result'attendees' = new Syncroton_Model_EventAttendee($att); @@ -316,6 +324,10 @@ // Recurrence (and exceptions) $this->recurrence_from_kolab($collection, $event, $result); + // RSVP status + $result'responseRequested' = $result'meetingStatus' == 3 && $user_rsvp ? 1 : 0; + $result'responseType' = $result'meetingStatus' == 3 ? $resp_type : null; + return $as_array ? $result : new Syncroton_Model_Event($result); }
View file
kolab-syncroton-2.3.10.tar.gz/lib/kolab_sync_timezone_converter.php -> kolab-syncroton-2.3.12.tar.gz/lib/kolab_sync_timezone_converter.php
Changed
@@ -204,8 +204,8 @@ if ($standardTransition) { $offsets'bias' = $standardTransition'offset'/60*-1; if ($daylightTransition) { - $offsets = $this->_generateOffsetsForTransition($offsets, $standardTransition, 'standard'); - $offsets = $this->_generateOffsetsForTransition($offsets, $daylightTransition, 'daylight'); + $offsets = $this->_generateOffsetsForTransition($offsets, $standardTransition, 'standard', $timezone); + $offsets = $this->_generateOffsetsForTransition($offsets, $daylightTransition, 'daylight', $timezone); //@todo how do we get the standardBias (is usually 0)? //$offsets'standardBias' = ... @@ -225,27 +225,28 @@ /** * Get offsets for timezone transition * - * @param array $_offsets Timezone offsets - * @param array $_transition Timezone transition information - * @param string $_type 'standard' or 'daylight' + * @param array $_offsets Timezone offsets + * @param array $_transition Timezone transition information + * @param string $_type Transition type: 'standard' or 'daylight' + * @param DateTimeZone $_timezone Timezone of the transition * * @return array */ - protected function _generateOffsetsForTransition(array $_offsets, array $_transition, $_type) + protected function _generateOffsetsForTransition(array $_offsets, array $_transition, $_type, $_timezone) { - $transitionDateParsed = new DateTime($_transition'time'); + $transitionDate = new DateTime($_transition'time', $_timezone); if ($_transition'offset') { - $transitionDateParsed->modify($_transition'offset' . ' seconds'); + $transitionDate->modify($_transition'offset' . ' seconds'); } - $_offsets$_type . 'Month' = (int) $transitionDateParsed->format('n'); - $_offsets$_type . 'DayOfWeek' = (int) $transitionDateParsed->format('w'); - $_offsets$_type . 'Minute' = (int) $transitionDateParsed->format('i'); - $_offsets$_type . 'Hour' = (int) $transitionDateParsed->format('G'); + $_offsets$_type . 'Month' = (int) $transitionDate->format('n'); + $_offsets$_type . 'DayOfWeek' = (int) $transitionDate->format('w'); + $_offsets$_type . 'Minute' = (int) $transitionDate->format('i'); + $_offsets$_type . 'Hour' = (int) $transitionDate->format('G'); for ($i=5; $i>0; $i--) { - if ($this->_isNthOcurrenceOfWeekdayInMonth($_transition'ts', $i)) { + if ($this->_isNthOcurrenceOfWeekdayInMonth($transitionDate, $i)) { $_offsets$_type . 'Day' = $i; break; }; @@ -257,22 +258,21 @@ /** * Test if the weekday of the given {@param $_timestamp} is the {@param $_occurence}th occurence of this weekday within its month. * - * @param int $_timestamp + * @param DateTime $_datetime * @param int $_occurence 1 to 5, where 5 indicates the final occurrence during the month if that day of the week does not occur 5 times * * @return bool */ - protected function _isNthOcurrenceOfWeekdayInMonth($_timestamp, $_occurence) + protected function _isNthOcurrenceOfWeekdayInMonth($_datetime, $_occurence) { if ($_occurence <= 1) { return true; } - $original = new DateTime('@'.$_timestamp); - $orig = $original->format('n'); + $orig = $_datetime->format('n'); if ($_occurence == 5) { - $modified = clone($original); + $modified = clone($_datetime); $modified->modify('1 week'); $mod = $modified->format('n'); @@ -280,7 +280,7 @@ return $mod > $orig || ($mod == 1 && $orig == 12); } - $modified = clone($original); + $modified = clone($_datetime); $modified->modify(sprintf('-%d weeks', $_occurence - 1)); $mod = $modified->format('n'); @@ -288,7 +288,7 @@ return false; } - $modified = clone($original); + $modified = clone($_datetime); $modified->modify(sprintf('-%d weeks', $_occurence)); $mod = $modified->format('n'); @@ -305,7 +305,7 @@ * * @return bool */ - protected function _checkTransition($_standardTransition, $_daylightTransition, $_offsets) + protected function _checkTransition($_standardTransition, $_daylightTransition, $_offsets, $tz) { if (empty($_standardTransition) || empty($_offsets)) { return false; @@ -327,16 +327,16 @@ $daylightOffsetMilestone = ($_offsets'bias' + ($_offsets'daylightBias' * -1) ) * 60 * -1; if ($daylightOffset == $_daylightTransition'offset' || $daylightOffsetMilestone == $_daylightTransition'offset') { - $standardParsed = getdate($_standardTransition'ts'); - $daylightParsed = getdate($_daylightTransition'ts'); + $standardDate = new DateTime($_standardTransition'time', $tz); + $daylightDate = new DateTime($_daylightTransition'time', $tz); - if ($standardParsed'mon' == $_offsets'standardMonth' && - $daylightParsed'mon' == $_offsets'daylightMonth' && - $standardParsed'wday' == $_offsets'standardDayOfWeek' && - $daylightParsed'wday' == $_offsets'daylightDayOfWeek' + if ($standardDate->format('n') == $_offsets'standardMonth' && + $daylightDate->format('n') == $_offsets'daylightMonth' && + $standardDate->format('w') == $_offsets'standardDayOfWeek' && + $daylightDate->format('w') == $_offsets'daylightDayOfWeek' ) { - return $this->_isNthOcurrenceOfWeekdayInMonth($_daylightTransition'ts', $_offsets'daylightDay') && - $this->_isNthOcurrenceOfWeekdayInMonth($_standardTransition'ts', $_offsets'standardDay'); + return $this->_isNthOcurrenceOfWeekdayInMonth($daylightDate, $_offsets'daylightDay') && + $this->_isNthOcurrenceOfWeekdayInMonth($standardDate, $_offsets'standardDay'); } } } @@ -524,7 +524,7 @@ { list($standardTransition, $daylightTransition) = $this->_getTransitionsForTimezoneAndYear($timezone, $this->_startDate'year'); - if ($this->_checkTransition($standardTransition, $daylightTransition, $offsets)) { + if ($this->_checkTransition($standardTransition, $daylightTransition, $offsets, $timezone)) { return $standardTransition; }
View file
kolab-syncroton-2.3.10.tar.gz/tests/timezone_converter.php -> kolab-syncroton-2.3.12.tar.gz/tests/timezone_converter.php
Changed
@@ -9,16 +9,32 @@ function test_list_timezones() { + date_default_timezone_set('America/Los_Angeles'); + $converter = timezone_converter_test::getInstance(); $input = 'AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAoAAAAEAAIAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAMAAAAFAAEAAAAAAAAAxP///w=='; $output = $converter->getListOfTimezones($input); $this->assertTrue(is_array($output)); + + $converter = timezone_converter_test::getInstance(); + $output = $converter->getListOfTimezones('xP///0MAZQBuAHQAcgBhAGwAIABFAHUAcgBvAHAAZQAgAFMAdABhAG4AZABhAHIAZAAgAFQAaQBtAGUAAAAAAAAAAAAAAAoAAAAFAAMAAAAAAAAAAAAAAEMAZQBuAHQAcgBhAGwAIABFAHUAcgBvAHAAZQAgAEQAYQB5AGwAaQBnAGgAdAAgAFQAaQBtAGUAAAAAAAAAAAAAAAMAAAAFAAIAAAAAAAAAxP///w=='); + + $this->assertTrue(is_array($output)); + $this->assertTrue(isset($output'Europe/Warsaw')); + + $converter = timezone_converter_test::getInstance(); + $output = $converter->getListOfTimezones('4AEAAFAAYQBjAGkAZgBpAGMAIABTAHQAYQBuAGQAYQByAGQAIABUAGkAbQBlAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAsAAAABAAIAAAAAAAAAAAAAAFAAYQBjAGkAZgBpAGMAIABEAGEAeQBsAGkAZwBoAHQAIABUAGkAbQBlAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAMAAAACAAIAAAAAAAAAxP///w=='); + + $this->assertTrue(is_array($output)); + $this->assertTrue(isset($output'America/Los_Angeles')); } function test_get_timezone() { + date_default_timezone_set('America/Los_Angeles'); + $converter = timezone_converter_test::getInstance(); $datetime = new DateTime('2017-01-01T12:00:00Z'); @@ -32,7 +48,7 @@ $this->assertSame('Europe/Warsaw', $output); - $offsets = $converter->getOffsetsForTimezone('America/Los_angeles', $datetime); + $offsets = $converter->getOffsetsForTimezone('America/Los_Angeles', $datetime); $output = $converter->getTimezone($offsets, 'America/Los_Angeles'); $this->assertSame('America/Los_Angeles', $output); @@ -40,6 +56,8 @@ function test_get_offsets_for_timezone() { + date_default_timezone_set('America/Los_Angeles'); + $converter = timezone_converter_test::getInstance(); $datetime = new DateTime('2017-01-01T12:00:00Z');
View file
kolab-syncroton.dsc
Changed
@@ -2,7 +2,7 @@ Source: kolab-syncroton Binary: kolab-syncroton Architecture: all -Version: 2.3.10-0~kolab1 +Version: 2.3.12-0~kolab1 Maintainer: Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen@kolabsys.com> Uploaders: Paul Klos <kolab@klos2day.nl> Homepage: http://www.kolab.org/ @@ -12,5 +12,5 @@ Package-List: kolab-syncroton deb utils extra Files: - 00000000000000000000000000000000 0 kolab-syncroton-2.3.10.tar.gz + 00000000000000000000000000000000 0 kolab-syncroton-2.3.12.tar.gz 00000000000000000000000000000000 0 debian.tar.gz
Locations
Projects
Search
Status Monitor
Help
Open Build Service
OBS Manuals
API Documentation
OBS Portal
Reporting a Bug
Contact
Mailing List
Forums
Chat (IRC)
Twitter
Open Build Service (OBS)
is an
openSUSE project
.