Ticket #2513: lazydate.patch
File lazydate.patch, 500 bytes (added by , 18 years ago) |
---|
-
django/db/models/__init__.py
47 47 return "<LazyDate: %s>" % self.delta 48 48 49 49 def __get_value__(self): 50 return datetime.datetime.now() + self.delta50 return (datetime.datetime.now() + self.delta).date() 51 51 52 52 def __getattr__(self, attr): 53 53 return getattr(self.__get_value__(), attr)