diff options
| author | pliablepixels <pliablepixels@gmail.com> | 2016-01-29 14:17:35 -0500 |
|---|---|---|
| committer | pliablepixels <pliablepixels@gmail.com> | 2016-01-29 14:17:35 -0500 |
| commit | a3090dd2d4af0de8829464874f572e1caed8e76c (patch) | |
| tree | 57834d955742c88aadc4ff1b81366347e16860ce /www/js/MonitorCtrl.js | |
| parent | 77bc8857ccaf16c70a68f95f750191b469bf07ff (diff) | |
#154 and #155 various updates, also ties into https://github.com/ZoneMinder/ZoneMinder/issues/1253
Former-commit-id: 7f939b4bad5d9463a7653abbdcafd79d8a6c1fa8
Diffstat (limited to 'www/js/MonitorCtrl.js')
| -rw-r--r-- | www/js/MonitorCtrl.js | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/www/js/MonitorCtrl.js b/www/js/MonitorCtrl.js index 6d77b4fe..6b712507 100644 --- a/www/js/MonitorCtrl.js +++ b/www/js/MonitorCtrl.js @@ -20,6 +20,8 @@ angular.module('zmApp.controllers') $scope.monitors = []; $scope.monitors = message; + + if ($scope.monitors.length == 0) { @@ -283,7 +285,7 @@ angular.module('zmApp.controllers') console.log("**VIEW ** Monitor Ctrl Unloaded"); }); - $scope.openModal = function (mid, controllable, controlid) { + $scope.openModal = function (mid, controllable, controlid, connKey) { ZMDataModel.zmDebug("MonitorCtrl:Open Monitor Modal with monitor Id=" + mid + " and Controllable:" + controllable + " with control ID:" + controlid); @@ -293,10 +295,13 @@ angular.module('zmApp.controllers') $scope.LoginData = ZMDataModel.getLogin(); $scope.rand = Math.floor(Math.random() * (999999 - 111111 + 1)) + 111111; $rootScope.rand = Math.floor(Math.random() * (999999 - 111111 + 1)) + 111111; + $scope.connKey = connKey; $scope.ptzMoveCommand = ""; $scope.presetOn = false; + + // This is a modal to show the monitor footage // We need to switch to always awake if set so the feed doesn't get interrupted @@ -400,7 +405,7 @@ angular.module('zmApp.controllers') // switch off awake, as liveview is finished ZMDataModel.setAwake(false); $scope.modal.remove(); - $timeout (function() {ZMDataModel.zmLog("Stopping network pull...");window.stop();},50); + $timeout (function() {ZMDataModel.zmLog("Stopping network pull...");if (ZMDataModel.isForceNetworkStop()) window.stop();},50); }; //Cleanup the modal when we're done with it! $scope.$on('$destroy', function () { |
