Answer the question
In order to leave comments, you need to log in
Django and timezones: what's the problem?
settings.py :
TIME_ZONE = 'Europe/Moscow'
USE_TZ = True
class Reserve(models.Model):
datetime = models.DateTimeField(
verbose_name='Дата и время'
)
Answer the question
In order to leave comments, you need to log in
Look at the time zone in the DBMS:
And look the same on the server:sudo dpkg-reconfigure tzdata
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question