Message1070
From: ron_dagostino@ssga.com
This affectes what you see in the GUI -- something with
activity yesterday actually shows activity
as "tomorrow", which is counter-intuitive.
>>> from roundup.date import Date
>>> from roundup.cgi.templating import
DateHTMLProperty
>>> client = Date('.')
>>> client.db = 1
>>> y = DateHTMLProperty(client, None, None, None,
None, Date('-1d'))
>>> y.reldate()
'tomorrow' <<<<<<<<<<<<<<<<<<<<
>>>
Here is a patch to the reldate() method of templating.py:
diff templating.py~ templating.py
1054c1054
< interval = date.Date('.') - self._value
---
> interval = self._value - date.Date('.')
bash-2.05b$
>>> from roundup.date import Date
>>> from roundup.cgi.templating import
DateHTMLProperty
>>> client = Date('.')
>>> client.db = 1
>>> y = DateHTMLProperty(client, None, None, None,
None, Date('-1d'))
>>> y.reldate()
'yesterday' <<< Fixed, plus the GUI is now correct
>>>
|
|
Date |
User |
Action |
Args |
2009-02-03 14:20:33 | admin | link | issue853345 messages |
2009-02-03 14:20:33 | admin | create | |
|