TodoTxtMac icon indicating copy to clipboard operation
TodoTxtMac copied to clipboard

filters could support relative dates

Open ianmorti opened this issue 10 years ago • 5 comments

This is an enhancement request.

It would be nice if I could add a filter for a relative date e.g. "due date is TODAY" or due date is less than 7 DAYS

Thanks.

ianmorti avatar Apr 25 '14 16:04 ianmorti

That is a good idea. I will consider it for a future version.

It would require an additional custom filter predicate to be created, and that predicate would have to use my date helper class to avoid timezone issues.

mjdescy avatar Apr 25 '14 16:04 mjdescy

In the past I have done that using aText text replacement. I have also done it on the command line using egrep.

careyb avatar Apr 30 '14 14:04 careyb

I have been working on a custom filter predicate editor row template. It is a tricky operation to develop these filters, partly because the filters are saved in the user defaults and corrupt filters essentially break the app. Right now, my version of the app is broken, most likely because of these changes to the filters. That is definitely slowing me down! :-(

mjdescy avatar Apr 30 '14 18:04 mjdescy

Any update on this request? If not, I'm tempted to crack open the source and help!

dominicwa avatar Jun 22 '16 03:06 dominicwa

There's no real update on this feature request. Predicate row editors are tricky to work with---that's the main reason no real work has been done on this. Assistance would be appreciated.

There are probably several ways to implement this. One simple way may be to create a predicate row template with several text options ("due this week", "due this month", or whatever) and then create computed properties in the TTMTask object that would evaluate to true/false for each of those named conditions. That's not exactly what was requested, but it is simpler than what is requested, and it might be a good start.

mjdescy avatar Jun 23 '16 01:06 mjdescy