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

Adding Visualize visualization to dashboard from modal directs user to dashboard listing page #89917

Closed
poffdeluxe opened this issue Feb 1, 2021 · 2 comments · Fixed by #90090
Labels
bug Fixes for quality problems that affect the customer experience Project:TimeToVisualize Team:Presentation Presentation Team for Dashboard, Input Controls, and Canvas

Comments

@poffdeluxe
Copy link
Contributor

Kibana version:
7.x/master

Describe the bug:
When adding a Visualize (not-Lens) visualization while using the new "add to dashboard" modal, instead of being redirected to the dashboard that the visualization should be added to, the user is redirected to the Dashboard listing page.

Steps to reproduce:

  1. From the sidebar, click Visualize and begin to add a non-Lens visualization
  2. While in the editor, select Save and from the modal, select the option to add to new dashboard.
  3. After saving, you end up on the Dashboard listing page

Expected behavior:
After saving, the user is taken to the Dashboard they saved the visualization to

Screenshots (if relevant):

@poffdeluxe poffdeluxe added bug Fixes for quality problems that affect the customer experience Team:Presentation Presentation Team for Dashboard, Input Controls, and Canvas Project:TimeToVisualize labels Feb 1, 2021
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-presentation (Team:Presentation)

@poffdeluxe
Copy link
Contributor Author

Discovered this while working on functional tests for Time-to-visualize

Prior to the state transfer navigation after saving, the Visualize app calls history.replace with the Visualize listing path: https://github.com/elastic/kibana/blob/master/src/plugins/visualize/public/application/utils/get_top_nav_config.tsx#L346-L347
The reason for this is so that if the user navigates to the Visualize app (from the menu), they aren't shown the editor and are instead shown the listing.

If I comment out those two lines, the redirect bug described in this issue is no longer present. I suspect that somehow the dashboard app is interpreting the history.replace as instructions for it and as a result redirects the user to the dashboard listing page.

Furthermore, I suspect this bug is linked to this PR: #87635
I checked out the commit prior to this PR's commit into master and the bug was not happening. I then checked out this PR's commit into master and the bug started happening

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Fixes for quality problems that affect the customer experience Project:TimeToVisualize Team:Presentation Presentation Team for Dashboard, Input Controls, and Canvas
Projects
None yet
2 participants