aboutsummaryrefslogtreecommitdiff
path: root/views.py
diff options
context:
space:
mode:
authorAlban Gruin2018-04-15 11:39:04 +0200
committerAlban Gruin2018-04-15 11:39:04 +0200
commit4efb7fb7e716788ff65fea74cba60e211b4944eb (patch)
tree71e4d4197d4e483397ff323679ee2e6b899380fe /views.py
parent3f2b67605dea039c9498a1c67a89ef6d5443e0a9 (diff)
On importe RawSQL que lorsqu’on utilise PostgreSQL
Diffstat (limited to 'views.py')
-rw-r--r--views.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/views.py b/views.py
index c3bcdc2..2a500c1 100644
--- a/views.py
+++ b/views.py
@@ -17,7 +17,6 @@ import datetime
from django.db import connection
from django.db.models import Count, Max
-from django.db.models.expressions import RawSQL
from django.db.models.functions import ExtractWeek, ExtractYear, Length
from django.http import Http404
from django.shortcuts import get_object_or_404, render
@@ -31,6 +30,7 @@ import edt
if connection.vendor == "postgresql":
from django.contrib.postgres.aggregates import ArrayAgg
+ from django.db.models.expressions import RawSQL
def index(request):
years = Year.objects.order_by("name")