aboutsummaryrefslogtreecommitdiff
path: root/db.py
diff options
context:
space:
mode:
authorAlban Gruin2017-02-11 12:34:20 +0100
committerAlban Gruin2017-02-11 12:34:20 +0100
commit7dc44ec77c6adcf7515f382d439d9a1820085d73 (patch)
treea703a4f97d51ce44a5f844cb2e3cbc49c9a4a7ff /db.py
parent3f03f5a058755e166ec69d992b012186434caa18 (diff)
Déplacement de ExtractWeek dans db.py
Diffstat (limited to 'db.py')
-rw-r--r--db.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/db.py b/db.py
index 678225e..80a8c95 100644
--- a/db.py
+++ b/db.py
@@ -22,6 +22,10 @@ from django.db.models.sql.query import Query
from django.db.models.sql.where import WhereNode
+class ExtractWeek(Extract):
+ lookup_name = "week"
+
+
class GroupedCompiler(SQLCompiler):
def get_group_by(self, select, order_by):
result = super(GroupedCompiler, self).get_group_by(select, order_by)