python - Django Time_Zone not saving correct values -
i have following settings in settings.py regarding time zones.
time_zone = 'asia/kolkata'  use_tz = true   using datetime field, save particular time
date: 2015-04-01 time: 22:00:00   it still gets stored 2015-04-01 16:30:00 in database on querying returns 04:30 pm 01/04/2015 in admin still shows
date: 2015-04-01 time: 22:00:00   how fix error? there setting i'm missing in settings.py?
with windows, have change operating system timezone able reliably work:
https://docs.djangoproject.com/en/1.7/ref/settings/#time-zone
note
django cannot reliably use alternate time zones in windows environment. if you’re running django on windows, time_zone must set match system time zone.
Comments
Post a Comment