-
Notifications
You must be signed in to change notification settings - Fork 14k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
No way to set current period as upper bound on query timeframe #5920
Comments
@betodealmeida |
BTW those libs are pretty powerful and can do much more than you probably think, statements like It would be cool to show more of what's supported out of our time-parsing function, and what it currently resolves to. Maybe an info bubble with some suggestion and some label showing what relative times map to as the person types, shows an alert when it doesn't compute. We'd need to run async requests against a new endpoint here to do this. |
Just to be sure: do we still want this new endpoint? Asking because the DateFilterControl widget and related code seems to have been updated quite often "recently". If yes, I'd like to pick this up. |
Related: #6360 |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
I know it's been time to this issue but I would like to share the trick I found for this issue |
The only options for setting the upper bound of the DateFilterControl dynamically with smart date parsing are:
Selecting last [period] sets the upper bound as the beginning of that period, e.g. if today is Sept. 18 and I set the upper bound as "last month", the upper bound will be August 1, i.e. the beginning of last month, which makes sense semantically since the data goes up until "last month".
However, there is no way to set the upper bound as the current period as far as I can tell, and this is important for creating visualizations that only include full weeks/months/etc. of data.
Example: If today is september 18 and I want to include data up until Sept 1, i.e. the last full month of data, I need to be able to enter "This month" as the upper bound, which sets the time frame as < Sept 1.
I'd be happy to submit a PR to add a "This x" option to the DateFilterControl, but I wanted to make sure I wasn't missing something first.
The text was updated successfully, but these errors were encountered: