After tapping notification

I’ve done push notification with phonegap-plugin-push and FCM. Now I have a problem. I need to do:

If user taps notification it will redirect him to one of tabs (with variable) in my app:
.state('czytaj', { url: '/czytaj/:newsId', templateUrl: 'templates/tab-czytaj.html', controller: 'CzytajCtrl' })

My code is standard:
FCMPlugin.onNotification( function(data){ if (data.wasTapped){ //Notification was received on device tray and tapped by the user. //alert(JSON.stringify(data)); } else { //Notification was received in foreground. Maybe the user needs to be notified. //alert(JSON.stringify(data)); } }, function(msg){ console.log('onNotification callback successfully registered: ' + msg); }, function(err){ console.log('Error registering onNotification callback: ' + err); } );