Angular & Ionic State Change and history

I'm quite new to AngularJS as well as Ionic. Was wondering if anyone could help me figure out how to set a certain history before a state change?

Currently I have $state.go('app.lineup',{ 'lineupId': navURLID}); and I want to point the back button to 'app.lineups' which is the parent for the 'app.lineup' page.

Everything in my code works well however when I redirect a user to another state the back button returns me to the state I sent them from and not the parent state that I need to send them to?

Any help (even in the form of internet references wink) will be greatly appreciated :).

Thanks a mil!

one way to do it is to not make the parent state as abstract, let it actually resolve the route and in the parent states controller redirect to the desired child something like

$state.go('parent',{child:'childname'})

where child is not a param but a search param, and from inside the parents controller you do

$state.go('parent.'+search.child,{any: param})

that way you'll always go through the parent state first.

other solution would be to use replace or you can also use the replace property of the options object in the $state.go function https://github.com/angular-ui/ui-router/wiki/Quick-Reference it depends on your structure.