From 6731d716f87cf22961c31b94af788f553db88d4b Mon Sep 17 00:00:00 2001 From: andibraeu Date: Sat, 16 Aug 2014 09:39:07 +0200 Subject: [PATCH 1/3] added link to ics file --- .../CalciferBundle/Resources/views/Event/index.html.twig | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/Hackspace/Bundle/CalciferBundle/Resources/views/Event/index.html.twig b/src/Hackspace/Bundle/CalciferBundle/Resources/views/Event/index.html.twig index e820215..287a5a6 100755 --- a/src/Hackspace/Bundle/CalciferBundle/Resources/views/Event/index.html.twig +++ b/src/Hackspace/Bundle/CalciferBundle/Resources/views/Event/index.html.twig @@ -24,6 +24,9 @@ {% if tag|default(false) %} für Tag „{{ tag.name }}“{% endif %} {% if location|default(false) %} für Ort „{{ location.name }}“{% endif %} + {% if tag|default(false) %} + Link zur Kalenderdatei + {% endif %} From fb735cfda8431f91edfa2984d27e0a26f8b469f2 Mon Sep 17 00:00:00 2001 From: andibraeu Date: Sat, 27 Sep 2014 17:49:16 +0200 Subject: [PATCH 2/3] missing endif --- .../Bundle/CalciferBundle/Resources/views/Event/index.html.twig | 1 + 1 file changed, 1 insertion(+) diff --git a/src/Hackspace/Bundle/CalciferBundle/Resources/views/Event/index.html.twig b/src/Hackspace/Bundle/CalciferBundle/Resources/views/Event/index.html.twig index b567157..b159874 100755 --- a/src/Hackspace/Bundle/CalciferBundle/Resources/views/Event/index.html.twig +++ b/src/Hackspace/Bundle/CalciferBundle/Resources/views/Event/index.html.twig @@ -28,6 +28,7 @@ {% if tag|default(false) %} Link zur Kalenderdatei + {% endif %} {% if location|default(false) %} {% if (location.description|length > 0) or location.hasAddress() %}
From c522653d6ff5e9d02e32197f8ad7b17b6cc604eb Mon Sep 17 00:00:00 2001 From: andibraeu Date: Sat, 27 Sep 2014 18:07:51 +0200 Subject: [PATCH 3/3] set uid on ics file, some calenders need it to distinguish events --- .../Bundle/CalciferBundle/Controller/TagController.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Hackspace/Bundle/CalciferBundle/Controller/TagController.php b/src/Hackspace/Bundle/CalciferBundle/Controller/TagController.php index 69ea0bb..1d0c43b 100755 --- a/src/Hackspace/Bundle/CalciferBundle/Controller/TagController.php +++ b/src/Hackspace/Bundle/CalciferBundle/Controller/TagController.php @@ -71,7 +71,7 @@ class TagController extends Controller if ($format == 'ics') { $calendar = new Calendar(); $calendar->setProdId('-//My Company//Cool Calendar App//EN'); - $calendar->setTimeZone(new \DateTimeZone('Europe/Berlin')); + $calendar->setTimeZone(new \DateTimeZone('Europe/Berlin')); foreach ($entities as $entity) { /** @var Event $entity */ @@ -82,6 +82,7 @@ class TagController extends Controller $event->setSummary($entity->summary); $event->setDescription($entity->description); $event->setUrl($entity->url); + $event->setUid($entity->slug); if ($entity->location instanceof Location) { $location = new \Jsvrcek\ICS\Model\Description\Location(); $location->setName($entity->location->name);