#19181: Document caveats about using DateQuerySet in templates when time zone
support is enabled.
---------------------------------+--------------------
     Reporter:  wiliamsouza83@…  |      Owner:  nobody
         Type:  Uncategorized    |     Status:  new
    Component:  Documentation    |    Version:  1.4
     Severity:  Normal           |   Keywords:  docs
 Triage Stage:  Unreviewed       |  Has patch:  0
Easy pickings:  0                |      UI/UX:  0
---------------------------------+--------------------
 Improve the the warning in
 
https://docs.djangoproject.com/en/dev/ref/models/querysets/#django.db.models.query.QuerySet.dates
 adding a example that when time zone settings.USE_TZ support is enabled
 and your time zone settings.TIME_ZONE is settled to America / Sao Paulo
 wich is UTC - 3 in BRT and UTC - 2 in BRST and DateQuerySet return "Oct.
 10, 2012, midnight" you will get "Oct. 9, 2012, 9, 00, 00". You should
 turn off local time when displaying DateQuerySet to avoid problems:

 {% load tz %}
 {% localtime off %}
 {% for month in date_list %}
     <p>{{ month }}</p>
 {% endfor %}
 {% endlocaltime %}

-- 
Ticket URL: <https://code.djangoproject.com/ticket/19181>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to