Skip to content
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

Loose of “pinned filter” when switching from dashboard to Discover (when using “Saved queries”) #53258

Closed
staniere opened this issue Dec 17, 2019 · 4 comments · Fixed by #54307
Assignees
Labels
Feature:Filters PR sent Team:Visualizations Visualization editors, elastic-charts and infrastructure

Comments

@staniere
Copy link

staniere commented Dec 17, 2019

Hello,
I used saved queries and it is quite useful for me ! 😄
But it brings me a drawback as newly pinned filters are erased when going from dashboard to Discover .

Example :
I open my "personalFilter" in Dashboard which add several filters in my bar
Then, I add another filter in my bar, and declare it as "pinned"
Then I switch to Discover
=> my newly created filter dissappear 😬

Do you know how to keep this pinned filter without saving request directly in Dashboard ? (I need to test it in Discover before saving it !)

PS :
Behavior seen in Kibana 7.4.2

@Bargs Bargs added Feature:Filters Team:Visualizations Visualization editors, elastic-charts and infrastructure labels Dec 17, 2019
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-app (Team:KibanaApp)

@Bargs
Copy link
Contributor

Bargs commented Dec 17, 2019

Thanks for reporting this issue, I was able to reproduce it myself. Looks like it might be a bug with how we're loading the filters from the saved query, because the pinned filter only disappears if you previously had a saved query loaded in Discover. I'll look into it 👍

@staniere
Copy link
Author

hello,
for information, issue does not appear again since I upgraded from kibana 7.4.2-1 to 7.5.1-1

It does no more remove pinned filters when I go from Dashboard to Discover, even i I selected "open search" in Discover (Menu "Open / Save" search disappeared from dashboard, so I need to activate it from Discover)

@Bargs
Copy link
Contributor

Bargs commented Jan 8, 2020

I can still reproduce in master. The steps I'm following:

  • Create or load a saved query (not a saved search) in Discover
  • Navigate to Dashboard
  • Create a pinned filter
  • Navigate back to Discover, filter is gone

@Bargs Bargs reopened this Jan 8, 2020
@Bargs Bargs self-assigned this Jan 8, 2020
@Bargs Bargs added the PR sent label Jan 8, 2020
Bargs pushed a commit that referenced this issue Jan 21, 2020
When we originally implemented Saved Queries we had them overwrite pinned filters on load and on clear. This caused the issue in #53258. If you have a saved query loaded in Discover for example and you navigate to a different app and then back to Discover, that saved query will get get reloaded since app state is retained when navigating back and forth between apps. If you created a pinned filter in between visits to Discover, it will get removed when the saved query is reloaded.

This issue made me reconsider our previous decision. I think pinned filters should not be affected by loading or clearing a saved query, since they are pinned they should only be removed if the user explicitly asks for it. This solves the reported issue and I also think it makes the UI more intuitive.
Bargs pushed a commit to Bargs/kibana that referenced this issue Jan 21, 2020
…c#54307)

When we originally implemented Saved Queries we had them overwrite pinned filters on load and on clear. This caused the issue in elastic#53258. If you have a saved query loaded in Discover for example and you navigate to a different app and then back to Discover, that saved query will get get reloaded since app state is retained when navigating back and forth between apps. If you created a pinned filter in between visits to Discover, it will get removed when the saved query is reloaded.

This issue made me reconsider our previous decision. I think pinned filters should not be affected by loading or clearing a saved query, since they are pinned they should only be removed if the user explicitly asks for it. This solves the reported issue and I also think it makes the UI more intuitive.
Bargs pushed a commit that referenced this issue Jan 22, 2020
#55473)

When we originally implemented Saved Queries we had them overwrite pinned filters on load and on clear. This caused the issue in #53258. If you have a saved query loaded in Discover for example and you navigate to a different app and then back to Discover, that saved query will get get reloaded since app state is retained when navigating back and forth between apps. If you created a pinned filter in between visits to Discover, it will get removed when the saved query is reloaded.

This issue made me reconsider our previous decision. I think pinned filters should not be affected by loading or clearing a saved query, since they are pinned they should only be removed if the user explicitly asks for it. This solves the reported issue and I also think it makes the UI more intuitive.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature:Filters PR sent Team:Visualizations Visualization editors, elastic-charts and infrastructure
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants