automatic setting the freebusy url for accounts

This commit is contained in:
Ralf Becker 2006-07-14 23:25:52 +00:00
parent 77678259e8
commit 8f26ec2b1b

View File

@ -319,7 +319,14 @@ class bocontacts extends socontacts
} }
} }
$data['photo'] = $this->photo_src($data['id'],$data['jpegphoto']); $data['photo'] = $this->photo_src($data['id'],$data['jpegphoto']);
// set freebusy_uri for accounts
if (!$data['freebusy_uri'] && !$data['owner'] && $data['account_id'])
{
static $fb_url;
if (!$fb_url && @is_dir(EGW_SERVER_ROOT.'/calendar/inc')) $fb_url = ExecMethod('calendar.bocal.freebusy_url','');
if ($fb_url) $data['freebusy_uri'] = $fb_url.urlencode($GLOBALS['egw']->accounts->id2name($data['account_id']));
}
return $data; return $data;
} }