Mercurial > p > roundup > code
changeset 2730:8a4a2e135a73 maint-0.7
merge from HEAD
| author | Richard Jones <richard@users.sourceforge.net> |
|---|---|
| date | Fri, 08 Oct 2004 00:34:58 +0000 |
| parents | 572746c94537 |
| children | 0d8b3b5f40ea |
| files | CHANGES.txt roundup/date.py |
| diffstat | 2 files changed, 5 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/CHANGES.txt Fri Oct 08 00:21:31 2004 +0000 +++ b/CHANGES.txt Fri Oct 08 00:34:58 2004 +0000 @@ -17,6 +17,7 @@ - extend OTK and session table value cols to TEXT (sf bug 1031271) - fix lookup of REMOTE_USER (sf bug 1002923) - new Interval props weren't created properly in rdbms +- date.Interval() now accepts an Interval as a spec (sf bug 1041266) 2004-07-21 0.7.6
--- a/roundup/date.py Fri Oct 08 00:21:31 2004 +0000 +++ b/roundup/date.py Fri Oct 08 00:34:58 2004 +0000 @@ -15,7 +15,7 @@ # BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE, # SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. # -# $Id: date.py,v 1.68.2.3 2004-09-29 07:31:32 richard Exp $ +# $Id: date.py,v 1.68.2.4 2004-10-08 00:34:58 richard Exp $ """Date, time and time interval handling. """ @@ -451,6 +451,9 @@ self.from_seconds(spec) elif type(spec) in (StringType, UnicodeType): self.set(spec, allowdate=allowdate, add_granularity=add_granularity) + elif isinstance(spec, Interval): + (self.sign, self.year, self.month, self.day, self.hour, + self.minute, self.second) = spec.get_tuple() else: if len(spec) == 7: self.sign, self.year, self.month, self.day, self.hour, \
