diff options
| author | Pliable Pixels <pliablepixels@gmail.com> | 2016-11-06 10:28:22 -0500 |
|---|---|---|
| committer | Pliable Pixels <pliablepixels@gmail.com> | 2016-11-06 10:28:22 -0500 |
| commit | 5b80d3916cd91d630a0142f76a87b4863b714203 (patch) | |
| tree | 4ac995a0eb3bc935f46800a5c3f0c2707ece9895 /www/js/EventDateTimeFilterCtrl.js | |
| parent | 36b084bd099ba6369a721a38ecd33db0eb666c20 (diff) | |
Fixes bug of indefinite loading after resetting custom timeline #360
Diffstat (limited to 'www/js/EventDateTimeFilterCtrl.js')
| -rw-r--r-- | www/js/EventDateTimeFilterCtrl.js | 27 |
1 files changed, 19 insertions, 8 deletions
diff --git a/www/js/EventDateTimeFilterCtrl.js b/www/js/EventDateTimeFilterCtrl.js index 4b28140d..24df1f52 100644 --- a/www/js/EventDateTimeFilterCtrl.js +++ b/www/js/EventDateTimeFilterCtrl.js @@ -48,14 +48,25 @@ angular.module('zmApp.controllers') // you are looking at a specific monitor ID // going back will only retain that monitor ID // so lets reload with all monitors - $ionicHistory.nextViewOptions({ - disableBack: true - }); - $state.go("events", { - "id": 0, - "playEvent":false - }); - return; + // + //console.log (">>> BACKVIEW="+$ionicHistory.backTitle()); + + if ($ionicHistory.backTitle() == 'Timeline') + { + $ionicHistory.goBack(); + } + else // in events, backview is undefined? + { + $ionicHistory.nextViewOptions({ + disableBack: true + }); + $state.go("events", { + "id": 0, + "playEvent":false + }); + return; + } + //$ionicHistory.goBack(); }; |
