-
Notifications
You must be signed in to change notification settings - Fork 4.4k
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
port hideParameters dashboard param upstream #2948
Conversation
@arikfr I realize this is a small feature and a bit of a hack, mozilla#163 has some more info about this:
-- @emtwo |
Woops. |
@arikfr a dashboard would have its own set of parameter values and typically wouldn't get updated. I do think that aside from the auto-dashboard generation, it's useful to be able to remove the parameter textboxes in a dashboard so it's more presentable. So perhaps it could have a "presentation mode" without the parameter text boxes and an "edit mode" with the text boxes. I'm not sure if that's what the "Static Parameter Value" functionality that you mentioned does (didn't read through that whole PR) |
Among the other things implemented in that PR, it also implements the ability to set a static value to a parameter when adding the query/widget to the dashboard. If you create static dashboards based on queries with parameters, this seems like what you need. When a static value is used, then no UI is rendered for it. |
@alison985 why would you expect to see API functionality changes? |
@arikfr When creating a dashboard via the API, how else would you set a parameter to "Add the parameter to the dashboard", "Map to existing parameter", or "Use static value for the parameter'? Or set the static value of a parameter for a widget? |
I guess what @alison985 means (correct me if I'm wrong) is that we were creating dashboards with the API and using the parameters. These static parameters sound like they will behave correctly in the UI - they won't show the textboxes. However, we won't be able to use static parameters via the API. Is this true? |
@alison985 @emtwo of course the API supports this, as otherwise the interface couldn't use this :) No API changes were required as these are just options we store in the Widget.options blob. |
Thanks! |
Original issue: mozilla#163
Issue to port upstream: mozilla#563
This allows you to add ?hideParameters=true to a dashboard to hide them in widgets.
Without this parameter:
With parameter: