diff options
| author | Pliable Pixels <pliablepixels@gmail.com> | 2018-01-09 14:02:41 -0500 |
|---|---|---|
| committer | Pliable Pixels <pliablepixels@gmail.com> | 2018-01-09 14:02:41 -0500 |
| commit | 8a537d2da05897a96154fe9da6b3db761072108a (patch) | |
| tree | 946e086e048438214f561b643e83815408c2dbea /www/js/PortalLoginCtrl.js | |
| parent | af2b59902e50264a9a34f4ca0a5bdf06ecc13b8d (diff) | |
#499 - handle proper push handling for when app is exited or alive (iOS testing is TBD)
Diffstat (limited to 'www/js/PortalLoginCtrl.js')
| -rw-r--r-- | www/js/PortalLoginCtrl.js | 97 |
1 files changed, 3 insertions, 94 deletions
diff --git a/www/js/PortalLoginCtrl.js b/www/js/PortalLoginCtrl.js index a7d25f84..838d107e 100644 --- a/www/js/PortalLoginCtrl.js +++ b/www/js/PortalLoginCtrl.js @@ -267,98 +267,7 @@ angular.module('zmApp.controllers').controller('zmApp.PortalLoginCtrl', ['$ionic return (d.promise); } - function evaluateTappedNotification() - { - var ld = NVRDataModel.getLogin(); - - - if ($rootScope.tappedNotification == 2) { // url launch - NVRDataModel.debug("Came via app url launch with mid="+$rootScope.tappedMid); - NVRDataModel.debug("Came via app url launch with eid="+$rootScope.tappedEid); - $rootScope.tappedNotification = 0; - $ionicHistory.nextViewOptions( - { - disableBack: true - }); - - if (parseInt($rootScope.tappedMid) > 0) - { - NVRDataModel.debug("Going to live view "); - $state.go("app.monitors", - {}, - { - reload: true - }); - return; - - } - - else if (parseInt($rootScope.tappedEid) > 0) { - NVRDataModel.debug("Going to events with EID=" + $rootScope.tappedEid); - $state.go("app.events", - { - //"id": $rootScope.tappedEid, - "id": 0, - "playEvent": true - }, - { - reload: true - }); - return; - } - // go with monitor first, then event - just because I feel like ;) - - - } - else if ($rootScope.tappedNotification == 1) // push - { - - - NVRDataModel.log("Came via push tap. onTapScreen=" + ld.onTapScreen); - //console.log ("***** NOTIFICATION TAPPED "); - $rootScope.tappedNotification = 0; - $ionicHistory.nextViewOptions( - { - disableBack: true - }); - - if (ld.onTapScreen == $translate.instant('kTapMontage')) - { - NVRDataModel.debug("Going to montage"); - $state.go("app.montage", - {}, - { - reload: true - }); - - return; - } - else if (ld.onTapScreen == $translate.instant('kTapEvents')) - { - NVRDataModel.debug("Going to events"); - $state.go("app.events", - { - "id": 0, - "playEvent": false - }, - { - reload: true - }); - return; - } - else // we go to live - { - NVRDataModel.debug("Going to live view "); - $state.go("app.monitors", - {}, - { - reload: true - }); - return; - } - } - - } + function unlock(idVerified) { @@ -442,8 +351,8 @@ angular.module('zmApp.controllers').controller('zmApp.PortalLoginCtrl', ['$ionic return; } - else - evaluateTappedNotification(); + //else + // evaluateTappedNotification(); }, |
