In a reporting client I'm working on now, there is a need to filter data by different conditions, among which are conditions based on date/time. Decided, that user first selects a predicate from a drop-down menu, then enters an absolute or relative date/time value in a textbox.
My issue concerns relative date/time values. Suggestion is to use shortcuts (
m) for value and sign (
+) to indicate in which direction it should be shifted from now.
For example, if now is 15:45,
[earlier than] [ -3h]-- means "up to 12:45"
[ later than] [ -2h]-- means "starting from 13:45"
[earlier than] [ +2h]-- means "up to 17:45"
[ later than] [ +1h]-- means "starting from 16:45"
Is my approach obvious and easy to understand? Are there some other common ways to solve this issue?
If user enters a value without sign, how it should be treated?
The main use-case is the following: first a user sets up all conditions, then saves the whole filter for further usage. Filters are created once after installing and sometimes when a user needs some specific report. Saved filters can be modified, but this won't happen often--maybe once a day or a week. Users are enterprise, not wide audience, so some sort of training/tutorial will be provided.