From 34156d81d4d613117151ee3bb8db3a8489a42da1 Mon Sep 17 00:00:00 2001 From: liangliangyy Date: Tue, 15 Oct 2024 22:10:41 +0800 Subject: [PATCH] =?UTF-8?q?=E5=85=B3=E9=97=AD=E6=97=B6=E5=8C=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- djangoblog/settings.py | 2 +- owntracks/views.py | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/djangoblog/settings.py b/djangoblog/settings.py index 54b00be2..fa970b52 100644 --- a/djangoblog/settings.py +++ b/djangoblog/settings.py @@ -153,7 +153,7 @@ def env_to_bool(env, default): USE_L10N = True -USE_TZ = True +USE_TZ = False # Static files (CSS, JavaScript, Images) # https://docs.djangoproject.com/en/1.10/howto/static-files/ diff --git a/owntracks/views.py b/owntracks/views.py index 6c87a2bf..1f4cb041 100644 --- a/owntracks/views.py +++ b/owntracks/views.py @@ -104,7 +104,6 @@ def get_datas(request): date = list(map(lambda x: int(x), request.GET.get('date').split('-'))) querydate = django.utils.timezone.datetime( date[0], date[1], date[2], 0, 0, 0) - querydate = django.utils.timezone.make_aware(querydate) nextdate = querydate + datetime.timedelta(days=1) models = OwnTrackLog.objects.filter( creation_time__range=(querydate, nextdate))