mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-06-26 04:41:41 +02:00
patch from christian binder
class.boical.inc.php 285: handle exceptions field on export (delimiter changed to ";") 295: handle TRANSP value (0 or 1) on export 554: handle exceptions field on import 568: handle TRANSP value (0 or 1) on import 774-777: set supported fields for recur_exceptions and non_blocking added support for handling non blocking events for vcal(1.0) and ical(2.0)
This commit is contained in:
parent
410a7a6c15
commit
5d3f5ef2e6
@ -282,7 +282,7 @@
|
|||||||
{
|
{
|
||||||
$days[] = date('Ymd',$day);
|
$days[] = date('Ymd',$day);
|
||||||
}
|
}
|
||||||
$attributes['EXDATE'] = implode(',',$days);
|
$attributes['EXDATE'] = implode(';',$days);
|
||||||
$parameters['EXDATE']['VALUE'] = 'DATE';
|
$parameters['EXDATE']['VALUE'] = 'DATE';
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
@ -292,7 +292,11 @@
|
|||||||
break;
|
break;
|
||||||
|
|
||||||
case 'TRANSP':
|
case 'TRANSP':
|
||||||
$attributes['TRANSP'] = $event['non_blocking'] ? 'TRANSPARENT' : 'OPAQUE';
|
if ($version == '1.0') {
|
||||||
|
$attributes['TRANSP'] = $event['non_blocking'] ? 1 : 0;
|
||||||
|
} else {
|
||||||
|
$attributes['TRANSP'] = $event['non_blocking'] ? 'TRANSPARENT' : 'OPAQUE';
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 'CATEGORIES':
|
case 'CATEGORIES':
|
||||||
@ -361,11 +365,12 @@
|
|||||||
$_vcalData = preg_replace("/[\r\n]+ /",'',$_vcalData);
|
$_vcalData = preg_replace("/[\r\n]+ /",'',$_vcalData);
|
||||||
|
|
||||||
$vcal = &new Horde_iCalendar;
|
$vcal = &new Horde_iCalendar;
|
||||||
if(!$vcal->parsevCalendar($_vcalData))
|
if(!$vcal->parsevCalendar($_vcalData)) {
|
||||||
{
|
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$version = $vcal->getAttribute('VERSION');
|
||||||
|
|
||||||
if(!is_array($this->supportedFields))
|
if(!is_array($this->supportedFields))
|
||||||
{
|
{
|
||||||
$this->setSupportedFields();
|
$this->setSupportedFields();
|
||||||
@ -557,7 +562,7 @@
|
|||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case 'EXDATE':
|
case 'EXDATE':
|
||||||
// ToDo: $vcardData['recur_exception'] = ...
|
$vcardData['recur_exception'] = $attributes['value'];
|
||||||
break;
|
break;
|
||||||
case 'SUMMARY':
|
case 'SUMMARY':
|
||||||
$vcardData['title'] = $attributes['value'];
|
$vcardData['title'] = $attributes['value'];
|
||||||
@ -571,7 +576,11 @@
|
|||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case 'TRANSP':
|
case 'TRANSP':
|
||||||
$vcardData['non_blocking'] = $attributes['value'] == 'TRANSPARENT';
|
if($version = '1.0') {
|
||||||
|
$vcardData['non_blocking'] = $attributes['value'] == 1;
|
||||||
|
} else {
|
||||||
|
$vcardData['non_blocking'] = $attributes['value'] == 'TRANSPARENT';
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
case 'PRIORITY':
|
case 'PRIORITY':
|
||||||
$vcardData['priority'] = (int) $this->priority_ical2egw[$attributes['value']];
|
$vcardData['priority'] = (int) $this->priority_ical2egw[$attributes['value']];
|
||||||
@ -794,7 +803,10 @@
|
|||||||
switch(strtolower($_productName))
|
switch(strtolower($_productName))
|
||||||
{
|
{
|
||||||
default:
|
default:
|
||||||
$this->supportedFields = $defaultFields[0];
|
$this->supportedFields = $defaultFields[0] + array(
|
||||||
|
'recur_exception' => 'recur_exception',
|
||||||
|
'non_blocking' => 'non_blocking',
|
||||||
|
);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
@ -964,7 +976,7 @@
|
|||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case 'EXDATE':
|
case 'EXDATE':
|
||||||
// ToDo: $vcardData['recur_exception'] = ...
|
$vcardData['recur_exception'] = $attributes['value'];
|
||||||
break;
|
break;
|
||||||
case 'SUMMARY':
|
case 'SUMMARY':
|
||||||
$vcardData['title'] = $attributes['value'];
|
$vcardData['title'] = $attributes['value'];
|
||||||
|
Loading…
x
Reference in New Issue
Block a user