From 12184b16e97d9f5c6c99d6bfe79b1e5c53464fb3 Mon Sep 17 00:00:00 2001 From: Alban Gruin Date: Fri, 20 Oct 2017 17:46:37 +0200 Subject: Ajout d’un calendrier ICS spécifique pour un groupe qui ne prend pas en compte les parents --- feeds.py | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'feeds.py') diff --git a/feeds.py b/feeds.py index c2c5b14..66be12e 100644 --- a/feeds.py +++ b/feeds.py @@ -87,6 +87,11 @@ class IcalFeed(Feed): "location": format_rooms(item.rooms.all())} +class IcalOnlyOneFeed(IcalFeed): + def items(self, obj): + return Course.objects.filter(groups=obj).order_by("begin") + + class RSSFeed(Feed): def get_object(self, request, year_slug, timetable_slug, group_slug): year, week = get_current_or_next_week() -- cgit v1.2.1