Roundup Tracker - Issues

Issue 2550629

classification
[PATCH] Calendar does not show 'today' in user's timezone
Type: behavior Severity: normal
Components: Web interface Versions: 1.4
process
Status: closed
:
: : richard, wolever
Priority: :

Created on 2010-01-12 05:32 by wolever, last changed 2010-01-29 05:52 by richard.

Messages
msg3994 Author: [hidden] (wolever) Date: 2010-01-12 05:32
The portion of the popup calendar component which is highlighted 'today' does not take into 
account user's timezones.

Here's a patch that fixes it:

diff -r 6712fd2127f7 roundup/cgi/templating.py
--- a/roundup/cgi/templating.py	Wed Dec 16 11:54:04 2009 -0500
+++ b/roundup/cgi/templating.py	Tue Jan 12 00:29:31 2010 -0500
@@ -2809,7 +2809,8 @@
 
         html will simply be a table.
         """
-        date_str  = request.form.getfirst("date", ".")
+        current_date = date.Date(".").local(request.client.db.getUserTimezone())
+        date_str  = request.form.getfirst("date", current_date)
         display   = request.form.getfirst("display", date_str)
         template  = request.form.getfirst("@template", "calendar")
         form      = request.form.getfirst("form")
msg3999 Author: [hidden] (richard) Date: 2010-01-29 05:52
Applied, thanks.
History
Date User Action Args
2010-01-29 05:52:35richardsetstatus: new -> closed
nosy: + richard
messages: + msg3999
2010-01-12 05:32:53wolevercreate