summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGeorg Ehrke <dev@georgswebsite.de>2012-06-30 15:23:21 +0200
committerGeorg Ehrke <dev@georgswebsite.de>2012-06-30 15:23:21 +0200
commit34b2486d5342aba7b9459ce1e27f5acf2e7629e4 (patch)
treeed8ab3df6b3460c0b830291853e95d430eae06a0
parent51173163ce71c8b2f7f4876ba3cb9def51f19125 (diff)
downloadnextcloud-server-34b2486d5342aba7b9459ce1e27f5acf2e7629e4.tar.gz
nextcloud-server-34b2486d5342aba7b9459ce1e27f5acf2e7629e4.zip
some improvements for calendar export
-rw-r--r--apps/calendar/lib/export.php5
1 files changed, 3 insertions, 2 deletions
diff --git a/apps/calendar/lib/export.php b/apps/calendar/lib/export.php
index cd248ce92a6..b05e758672b 100644
--- a/apps/calendar/lib/export.php
+++ b/apps/calendar/lib/export.php
@@ -37,7 +37,8 @@ class OC_Calendar_Export{
*/
private static function calendar($id){
$events = OC_Calendar_Object::all($id);
- $return = "BEGIN:VCALENDAR\nVERSION:2.0\nPRODID:ownCloud Calendar " . OCP\App::getAppVersion('calendar') . "\n";
+ $calendar = OC_Calendar_Calendar::find($id);
+ $return = "BEGIN:VCALENDAR\nVERSION:2.0\nPRODID:ownCloud Calendar " . OCP\App::getAppVersion('calendar') . "\nX-WR-CALNAME:" . $calendar['displayname'] . "\n";
foreach($events as $event){
$return .= self::generateEvent($event);
}
@@ -52,7 +53,7 @@ class OC_Calendar_Export{
*/
private static function event($id){
$event = OC_Calendar_Object::find($id);
- $return = "BEGIN:VCALENDAR\nVERSION:2.0\nPRODID:ownCloud Calendar " . OCP\App::getAppVersion('calendar') . "\n";
+ $return = "BEGIN:VCALENDAR\nVERSION:2.0\nPRODID:ownCloud Calendar " . OCP\App::getAppVersion('calendar') . "\nX-WR-CALNAME:" . $event['summary'] . "\n";
$return .= self::generateEvent($event);
$return .= "END:VCALENDAR";
return $return;