angularjs - Avoid state transition occuring twice in $state.go or uisref -
using uirouter, trying navigate child state [a.childa url "localhost:90/a/childa/212"]to different state [b], transition occuring twice [like on click of button url changes "localhost:90/a/childa/212" localhost:90/a/childa , on clicking again changes localhost:90/b". need localhost:90/a/childa/212 directly change localhost:90/b using uisref or $state.go. how can it?
$stateprovider.state('a', { url: '/a', templateurl: 'assets/templates/a.html', controller: 'actrl' }).state('a.childa', { url: '/childa/:id', templateurl: 'assets/templates/childa.html', controller: 'childactrl' }); $stateprovider.state('b', { url: '/b', templateurl: 'assets/templates/b.html', controller: 'bctrl' });
Comments
Post a Comment