Skip to content
Snippets Groups Projects
Verified Commit f015c8a2 authored by Jonathan Weth's avatar Jonathan Weth :keyboard:
Browse files

Fix query in filter_group

parent 90d76062
No related branches found
No related tags found
1 merge request!45Improve handling of child/parent groups
......@@ -130,7 +130,7 @@ class LessonDataQuerySet(models.QuerySet):
if isinstance(group, int):
group = Group.objects.get(pk=group)
if group.parent_groups:
if group.parent_groups.all():
# Prevent to show lessons multiple times
return self.filter(Q(**{self._period_path + "lesson__groups": group}))
else:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment