Go to specific tab view


I made an app that receive push notification, after loading some parameter in a dafault view I use $state.go to change page, all go right, but I want that state.go uses the right ion-nav-view to load the page and the action get reflected to tab icons


$rootScope.$on(’$cordovaPush:notificationReceived’, function(event, notification) {
if (notification.alert) {
$scope.location = true;

use, div ng-show = location for specific tab view and hide other tabs


Sorry, but I don’t understand

I have a tab like this

 <ion-tab title="Chat" badge="nrchat" badge-style="badge-energized" icon-off="ion-ios-chatboxes-outline" icon-on="ion-ios-chatboxes" href="#/tab/listachat">
<ion-nav-view name="tab-chat"></ion-nav-view>

it’s not the default tab, but I want the app use this, where have I to put div ng-show thing?
is location “#/tab/listachat”?


< ion-tab title=“Chat” badge=“nrchat” badge-style=“badge-energized” icon-off=“ion-ios-chatboxes-outline” icon-on=“ion-ios-chatboxes” href="#/tab/listachat">
< div ng-show = location>
< /div>
< ion-nav-view name=“tab-chat”>


You can use $ionicTabsDelegate.select(index); to programatically change the tab.