diff options
| author | Pliable Pixels <pliablepixels@gmail.com> | 2019-03-25 16:01:13 -0400 |
|---|---|---|
| committer | Pliable Pixels <pliablepixels@gmail.com> | 2019-03-25 16:01:13 -0400 |
| commit | 9c4fb098bab9e69b25c969dd2ef87a864e809337 (patch) | |
| tree | f03e74e1e82c3e07f38539fcdcd7ce0a87a69bfd /www | |
| parent | 12f6856f911d8ee7c47f3116ed7f37b6e4ef9752 (diff) | |
timeline custom range goes to event
Diffstat (limited to 'www')
| -rw-r--r-- | www/js/EventDateTimeFilterCtrl.js | 33 |
1 files changed, 27 insertions, 6 deletions
diff --git a/www/js/EventDateTimeFilterCtrl.js b/www/js/EventDateTimeFilterCtrl.js index 07eea5db..51ebe91f 100644 --- a/www/js/EventDateTimeFilterCtrl.js +++ b/www/js/EventDateTimeFilterCtrl.js @@ -47,7 +47,7 @@ angular.module('zmApp.controllers') // going back will only retain that monitor ID // so lets reload with all monitors // - //console.log (">>> BACKVIEW="+$ionicHistory.backTitle()); + if ($ionicHistory.backTitle() == 'Timeline') { $ionicHistory.nextViewOptions({ @@ -119,14 +119,35 @@ angular.module('zmApp.controllers') // // var startDate = moment(temp).format("YYYY-MM-DD hh:mm:ss"); NVR.debug("DateTimeFilter: From/To is now: " + $rootScope.fromString + " & " + $rootScope.toString); + $ionicHistory.nextViewOptions({ disableBack: true }); - $state.go("app.events", { - "id": 0, - "playEvent": false - }); - return; + + console.log (" >>>>>>>> BACK VIEW = "+$ionicHistory.backTitle()); + + if ($ionicHistory.backTitle() == 'Timeline') { + $ionicHistory.nextViewOptions({ + disableBack: true + }); + $state.go("app.timeline", { + "id": 0, + "playEvent": false + }); + return; + } else // in events, backview is undefined? + { + $ionicHistory.nextViewOptions({ + disableBack: true + }); + $state.go("app.events", { + "id": 0, + "playEvent": false + }); + return; + } + + }; } |
