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

bug: TabPage & nav.pop() not working as it should #5196

Closed
lordgreg opened this issue Jan 26, 2016 · 6 comments
Closed

bug: TabPage & nav.pop() not working as it should #5196

lordgreg opened this issue Jan 26, 2016 · 6 comments
Assignees
Milestone

Comments

@lordgreg
Copy link

Type: bug

Ionic Version: 2.x

Platform: all

1. Have a child TabPage
2. Have 2 child Pages of TabPage (TabPageDetail and TabPageMoreInfo)
3. TabPage and TabPageDetail Controllers run.
4. Make button with goBack() function in TabPageDetail, which will run nav.pop()
5. Failure.
5.1 In browser: Black content shows up, but tabs stay, including nav-bar from TabPage
5.2 On Android device: Previous page appears in content, but TabPage nav and tabs stay. Previous Page is unusable (example: if we came to the listview, it isn't scrollable)
6. Basically, we're brought to TabPage from TabPageDetail, where previous page content is loaded.

how should it work?

  1. nav.pop() OR nav.backToRoot (pseudo) should bring us to previous state aka. to working previous page.
  2. ???
  3. profit.

@adamdbradley
Copy link
Contributor

Would you be able to provide a simple example? I'm not really following what you're trying to do, thanks

@lordgreg
Copy link
Author

lordgreg commented Feb 9, 2016

@adamdbradley @mhartington @brandyscarney

I've created a simple example (github page) of the problem described above. It should be self-explanatory.

Just clone the project with

git clone https://github.com/lordgreg/ionic2TabsNavigationProblem.git

and run npm install, then ionic serve.

As I understand, this 'bug' is currently on-the-wait since Ionic team is waiting for Angular2 Routing component to be upgraded? If so, can you provide any other workaround on this bug?

@MathiasTim
Copy link

👍 having the same issue here

@adamdbradley
Copy link
Contributor

Should be fixed up now, thanks!

@lordgreg
Copy link
Author

Dripping to try the bugfix out in the next release!

Many thanks @adamdbradley and others from Ionic Team 👍

@dongbe
Copy link

dongbe commented Nov 4, 2016

The navController of the previous page is overidden by the navController of the TabPage. (the bus is also present in rc1)
a tip is to save the previous navController and use it later
nav.push(TabPage,{previousNav : navCtrl});
...
navParams.data.previousNav.pop();

@ionitron-bot ionitron-bot bot locked and limited conversation to collaborators Sep 8, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants