I wanna do a simple app with the following structure but I am struggling of how to implement the views/view structure with <nav-view>
or <ui-view>
respectivel. It’s hard to explain the problem but I hope it becomes clear with the diagram and the explanations…
There are two main views:
tabs.list
A view with two children-views:
- tabs.list.new
- tabs.list.details
In ‘tabs.list’ you have a list. In the view “tabs.list.new” you can insert new items on the list. In the view “tabs.list.detail” you can see details of the inserted items.
tabs.suggestions
A simple view with one children-view:
- tabs.suggestions.details
You have a list with suggestions for what you could put on your list. You click on a suggestion and you get some details. On the “suggestions.details” view you have the functionality to go to directly to the ‘tabs.list.new’ view and the input field is already filled with the suggestion (red arrow).
As soon as I am directed to the ‘tabs.list.new’ view the history should behave as if I came from the state ‘tabs.list’ (click on the back button brings me back to “tabs.list” view).
What is the parameter for $state.go in order to redirect me form the view “tabs.suggestions.detail” to “tabs.list.new” while keeping the history as I wanted?