aboutsummaryrefslogtreecommitdiff
path: root/models.py
diff options
context:
space:
mode:
Diffstat (limited to 'models.py')
-rw-r--r--models.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/models.py b/models.py
index 87c4ca4..ff4897b 100644
--- a/models.py
+++ b/models.py
@@ -122,7 +122,7 @@ class Room(models.Model):
class CourseManager(GroupedManager):
def __get_weeks(self, qs):
extractYear = ExtractYear("begin")
- qs = qs.group_by("groups", "year", "week").order_by("groups__name", "year", "week")
+ qs = qs.group_by("groups", "year", "week", "groups__timetable", "groups__mention", "groups__subgroup", "groups__td", "groups__tp", "begin", "groups__name").order_by("groups__name", "year", "week")
if connection.vendor == "postgresql":
return qs.annotate(week=ExtractWeek("begin"), year=extractYear)