diff --git a/calendar/inc/class.calendar_activesync.inc.php b/calendar/inc/class.calendar_activesync.inc.php index 0cf621c0d3..5e9071b020 100755 --- a/calendar/inc/class.calendar_activesync.inc.php +++ b/calendar/inc/class.calendar_activesync.inc.php @@ -287,6 +287,11 @@ class calendar_activesync implements activesync_plugin_read if (!($etag = $this->calendar->get_etag($id))) { $stat = false; + // error_log why access is denied (should nevery happen for everything returned by calendar_bo::search) + $backup = $this->calendar->debug; + $this->calendar->debug = 2; + $this->check_perms(EGW_ACL_FREEBUSY, $id, 0, 'server'); + $this->calendar->debug = $backup; } else { diff --git a/calendar/inc/class.calendar_bo.inc.php b/calendar/inc/class.calendar_bo.inc.php index f63b2d95c7..64d2854220 100644 --- a/calendar/inc/class.calendar_bo.inc.php +++ b/calendar/inc/class.calendar_bo.inc.php @@ -186,7 +186,7 @@ class calendar_bo */ function __construct() { - if ($this->debug > 0) $this->debug_message('bocal::bocal() started',True,$param); + if ($this->debug > 0) $this->debug_message('calendar_bo::bocal() started',True,$param); $this->so = new calendar_so(); $this->datetime = $GLOBALS['egw']->datetime; @@ -422,7 +422,7 @@ class calendar_bo $offset = isset($params['offset']) && $params['offset'] !== false ? (int) $params['offset'] : false; if ($this->debug && ($this->debug > 1 || $this->debug == 'search')) { - $this->debug_message('bocal::search(%1) start=%2, end=%3, daywise=%4, cat_id=%5, filter=%6, query=%7, offset=%8, num_rows=%9, order=%10, sql_filter=%11)', + $this->debug_message('calendar_bo::search(%1) start=%2, end=%3, daywise=%4, cat_id=%5, filter=%6, query=%7, offset=%8, num_rows=%9, order=%10, sql_filter=%11)', True,$params,$start,$end,$daywise,$cat_id,$filter,$params['query'],$offset,(int)$params['num_rows'],$params['order'],$params['sql_filter']); } // date2ts(,true) converts to server time, db2data converts again to user-time @@ -539,7 +539,7 @@ class calendar_bo } if ($this->debug && ($this->debug > 0 || $this->debug == 'search')) { - $this->debug_message('bocal::search(%1)=%2',True,$params,$events); + $this->debug_message('calendar_bo::search(%1)=%2',True,$params,$events); } return $events; } @@ -635,13 +635,13 @@ class calendar_bo { if ((int) $this->debug >= 2 || $this->debug == 'check_move_horizont') { - $this->debug_message('bocal::check_move_horizont(%1) horizont=%2',true,$new_horizont,$this->config['horizont']); + $this->debug_message('calendar_bo::check_move_horizont(%1) horizont=%2',true,$new_horizont,$this->config['horizont']); } $new_horizont = $this->date2ts($new_horizont,true); // now we are in server-time, where this function operates if ($new_horizont <= $this->config['horizont']) // no move necessary { - if ($this->debug == 'check_move_horizont') $this->debug_message('bocal::check_move_horizont(%1) horizont=%2 is bigger ==> nothing to do',true,$new_horizont,$this->config['horizont']); + if ($this->debug == 'check_move_horizont') $this->debug_message('calendar_bo::check_move_horizont(%1) horizont=%2 is bigger ==> nothing to do',true,$new_horizont,$this->config['horizont']); return; } if (!empty($GLOBALS['egw_info']['server']['calendar_horizont'])) @@ -651,7 +651,7 @@ class calendar_bo if (empty($maxdays)) $maxdays = 1000; // old default if ($new_horizont > time()+$maxdays*DAY_s) // some user tries to "look" more then the maximum number of days in the future { - if ($this->debug == 'check_move_horizont') $this->debug_message('bocal::check_move_horizont(%1) horizont=%2 new horizont more then 1000 days from now --> ignoring it',true,$new_horizont,$this->config['horizont']); + if ($this->debug == 'check_move_horizont') $this->debug_message('calendar_bo::check_move_horizont(%1) horizont=%2 new horizont more then 1000 days from now --> ignoring it',true,$new_horizont,$this->config['horizont']); $new_horizont = time()+$maxdays*DAY_s; } if ($new_horizont < time()+31*DAY_s) @@ -668,7 +668,7 @@ class calendar_bo { if ($this->debug == 'check_move_horizont') { - $this->debug_message('bocal::check_move_horizont(%1): calling set_recurrences(%2,%3)',true,$new_horizont,$event,$old_horizont); + $this->debug_message('calendar_bo::check_move_horizont(%1): calling set_recurrences(%2,%3)',true,$new_horizont,$event,$old_horizont); } // insert everything behind max(cal_start), which can be less then $old_horizont because of bugs in the past $this->set_recurrences($event,egw_time::server2user($recuring[$cal_id]+1)); // set_recurences operates in user-time! @@ -678,7 +678,7 @@ class calendar_bo $config = CreateObject('phpgwapi.config','calendar'); $config->save_value('horizont',$this->config['horizont'],'calendar'); - if ($this->debug == 'check_move_horizont') $this->debug_message('bocal::check_move_horizont(%1) new horizont=%2, exiting',true,$new_horizont,$this->config['horizont']); + if ($this->debug == 'check_move_horizont') $this->debug_message('calendar_bo::check_move_horizont(%1) new horizont=%2, exiting',true,$new_horizont,$this->config['horizont']); } /** @@ -693,7 +693,7 @@ class calendar_bo { if ($this->debug && ((int) $this->debug >= 2 || $this->debug == 'set_recurrences' || $this->debug == 'check_move_horizont')) { - $this->debug_message('bocal::set_recurrences(%1,%2)',true,$event,$start); + $this->debug_message('calendar_bo::set_recurrences(%1,%2)',true,$event,$start); } // check if the caller gave us enough information and if not read it from the DB if (!isset($event['participants']) || !isset($event['start']) || !isset($event['end'])) @@ -750,7 +750,7 @@ class calendar_bo */ function db2data(&$events,$date_format='ts') { - if (!is_array($events)) echo "
bocal::db2data(\$events,$date_format) \$events is no array
\n".function_backtrace()."
calendar_bo::db2data(\$events,$date_format) \$events is no array
\n".function_backtrace()."
'.$msg."
\n".($backtrace ? 'Backtrace: '.function_backtrace(1)."
'.$msg."
\n".($backtrace ? 'Backtrace: '.function_backtrace(1)."