I have the following structure AllTasks -> ConcreteTask -> SubTask
. I use UINavigationController
, user always may understand her currenct location: i.e. on ConcreteTask
screen she has back
button that takes her to AllTasks
screen.
Say, Task1
is opened, and my app obtains new data for Task # 42. It displays alert (UIAlertController
) saying "There is update for Task # 42. Do you want to open it?". User clicks "yes", and my app should open Task42
screen.
What should I do with my navigation in this case?
Idea 1:
Add Task42
to my navigation stack and open it.
So, navigation would be AllTasks -> Task1 -->Task42
. When user click back
button, app will open Task1
page.
I dislike this idea because it breaks navigation and confuses user. Instead of tree, we now have mess. What if user close my app and open it next day? She will see Task42
page with back
button that takes her to some random task!
Idea 2
Drain navigation stack to AllTasks
and then open Task42
.
So, navigation would be AllTasks -->Task42
. When user click back button, app will open AllTasks
page. No more mess.
But I dislike this idea because it is not easy for user to go back to Task1
. She probably spent some time reading Task1
and now my app simply closed it.
Does there is a beautiful way to solve it?