in reply to Re: Re: Template Toolkit and Date plugin
in thread Template Toolkit and Date plugin
Yes, but I think you're confusing the issue. Finding out whether or not a date is after today is NOT display-related. A display-related issue would be formatting a date, or splitting an array into two columns.
"Is this date in the future?" is something you should be able to ask your data model. If adding a boolean feels too artificial to you, and the date object you've chosen has no "is_future" sort of method, then I'd suggest making a wrapper object you can use in your application that extends the date object to answer this question. Then just call it from TT.
|
|---|