Fix from Markus Warg for handling of confidential events.

This commit is contained in:
Andrew McMillan 2009-03-20 13:08:10 +13:00
parent a4cc016b39
commit 68d42aeb26
2 changed files with 5 additions and 4 deletions

View File

@ -62,11 +62,10 @@ else if ( $qry->rows == 1 && ! $request->IsCollection() ) {
$confidential->SetProperties( $first->GetProperties('RRULE'), 'RRULE' );
$confidential->SetProperties( $first->GetProperties('DURATION'), 'DURATION' );
$confidential->SetProperties( $first->GetProperties('DTEND'), 'DTEND' );
$confidential->SetProperties( $first->GetProperties('UID'), 'UID' );
$vcal = new iCalComponent();
$vcal->VCalendar();
$vcal->AddComponent($confidential);
$event->caldav_data = $vcal->Render();
$ical->SetComponents( array($confidential), $confidential->GetType() );
$event->caldav_data = $ical->Render();
$allowed = true;
}
else {
@ -142,6 +141,7 @@ else {
$confidential->SetProperties( $resource->GetProperties('RRULE'), 'RRULE' );
$confidential->SetProperties( $resource->GetProperties('DURATION'), 'DURATION' );
$confidential->SetProperties( $resource->GetProperties('DTEND'), 'DTEND' );
$confidential->SetProperties( $resource->GetProperties('UID'), 'UID' );
$vcal->AddComponent($confidential);
}

View File

@ -95,6 +95,7 @@ function calendar_to_xml( $properties, $item ) {
$confidential->SetProperties( $first->GetProperties('RRULE'), 'RRULE' );
$confidential->SetProperties( $first->GetProperties('DURATION'), 'DURATION' );
$confidential->SetProperties( $first->GetProperties('DTEND'), 'DTEND' );
$confidential->SetProperties( $first->GetProperties('UID'), 'UID' );
$ical->SetComponents(array($confidential),$confidential->GetType());
$caldav_data = $ical->Render();