diff --git a/roundup/date.py b/roundup/date.py
index c170fb6b3ac3c61c5f2921ce8fc984cf47b572aa..c40c4dc3288fda5b2475d3fe0df5f14baf46e561 100644 (file)
--- a/roundup/date.py
+++ b/roundup/date.py
# BASIS, AND THERE IS NO OBLIGATION WHATSOEVER TO PROVIDE MAINTENANCE,
# SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
#
-# $Id: date.py,v 1.20 2002-02-21 23:34:51 richard Exp $
+# $Id: date.py,v 1.21 2002-05-15 06:32:46 richard Exp $
__doc__ = """
Date, time and time interval handling.
def pretty(self):
''' print up the date date using one of these nice formats..
'''
- if self.year or self.month > 2:
- return None
+ if self.year:
+ if self.year == 1:
+ return _('1 year')
+ else:
+ return _('%(number)s years')%{'number': self.year}
elif self.month or self.day > 13:
days = (self.month * 30) + self.day
if days > 28:
#
# $Log: not supported by cvs2svn $
+# Revision 1.20 2002/02/21 23:34:51 richard
+# Oops, there's 24 hours in a day, and subtraction of intervals now works
+# properly.
+#
# Revision 1.19 2002/02/21 23:11:45 richard
# . fixed some problems in date calculations (calendar.py doesn't handle over-
# and under-flow). Also, hour/minute/second intervals may now be more than