summaryrefslogtreecommitdiff
path: root/www/js
diff options
context:
space:
mode:
Diffstat (limited to 'www/js')
-rw-r--r--www/js/MonitorModalCtrl.js4
-rw-r--r--www/js/MontageCtrl.js12
-rw-r--r--www/js/NVR.js13
3 files changed, 22 insertions, 7 deletions
diff --git a/www/js/MonitorModalCtrl.js b/www/js/MonitorModalCtrl.js
index bf6c95dd..1f0ce944 100644
--- a/www/js/MonitorModalCtrl.js
+++ b/www/js/MonitorModalCtrl.js
@@ -421,6 +421,7 @@ angular.module('zmApp.controllers').controller('MonitorModalCtrl', ['$scope', '$
var apiurl = NVR.getLogin().apiurl;
var alarmurl = apiurl + "/monitors/alarm/id:" + $scope.monitorId + "/command:status.json?"+$rootScope.authSession;
NVR.log("Invoking " + alarmurl);
+ console.log ("ALARM = "+alarmurl);
$http.get(alarmurl)
.then(function (data) {
@@ -1061,6 +1062,7 @@ angular.module('zmApp.controllers').controller('MonitorModalCtrl', ['$scope', '$
var c = mode == 'on' ? 'on' : 'off';
var alarmurl = apiurl + "/monitors/alarm/id:" + mid + "/command:" + c + ".json?"+$rootScope.authSession;
NVR.log("Invoking " + alarmurl);
+
var status = mode ? $translate.instant('kForcingAlarm') : $translate.instant('kCancellingAlarm');
$ionicLoading.show({
@@ -1257,7 +1259,7 @@ angular.module('zmApp.controllers').controller('MonitorModalCtrl', ['$scope', '$
var stream;
- var fps = NVR.getLogin().liveFPS;
+ var fps = NVR.getLogin().singleliveFPS;
stream = $scope.monitor.Monitor.streamingURL +
"/nph-zms?mode=" + getSingleStreamMode() +
"&monitor=" + $scope.monitorId +
diff --git a/www/js/MontageCtrl.js b/www/js/MontageCtrl.js
index e5274b81..c350df78 100644
--- a/www/js/MontageCtrl.js
+++ b/www/js/MontageCtrl.js
@@ -596,7 +596,7 @@ angular.module('zmApp.controllers')
apiurl += '.json?sort=StartTime&direction=desc&limit=1'+$rootScope.authSession;
- NVR.debug ("Getting event count");
+ NVR.debug ("Getting event count "+apiurl);
$http.get(apiurl)
.then (function (data) {
// console.log ("EVENTS GOT: "+JSON.stringify(data));
@@ -2022,6 +2022,7 @@ angular.module('zmApp.controllers')
$scope.constructStream = function (monitor) {
var stream;
+ var fps = NVR.getLogin().montageliveFPS;
if (currentStreamState == streamState.STOPPED || monitor.Monitor.listDisplay == 'noshow' ) {
//console.log ("STREAM=empty and auth="+$rootScope.authSession);
return "";
@@ -2033,8 +2034,13 @@ angular.module('zmApp.controllers')
"&monitor=" + monitor.Monitor.Id +
"&scale=" + $scope.LoginData.montageQuality +
"&rand=" + randToAvoidCacheMem + monitor.Monitor.Id +
- "&buffer=1000" +
- $rootScope.authSession +
+ "&buffer=1000"
+
+ if (fps) {
+ stream +='&maxfps='+fps;
+ }
+
+ stream += $rootScope.authSession +
appendConnKey(monitor.Monitor.connKey);
if (stream) stream += NVR.insertBasicAuthToken();
diff --git a/www/js/NVR.js b/www/js/NVR.js
index c9991d80..41cb3118 100644
--- a/www/js/NVR.js
+++ b/www/js/NVR.js
@@ -124,7 +124,8 @@ angular.module('zmApp.controllers')
'eventServerInterval': '', // list of intervals for all monitors
'refreshSec': '2', // timer value for frame change in sec
'refreshSecLowBW': 8,
- 'liveFPS':'',
+ 'singleliveFPS':'',
+ 'montageliveFPS':'',
'enableLogs': true,
'enableDebug': true, // if enabled with log messages with "debug"
'usePin': false,
@@ -1243,9 +1244,15 @@ angular.module('zmApp.controllers')
}
- if (typeof loginData.liveFPS == 'undefined') {
+ if (typeof loginData.singleliveFPS == 'undefined') {
- loginData.liveFPS = '';
+ loginData.singleliveFPS = '';
+
+ }
+
+ if (typeof loginData.montageliveFPS == 'undefined') {
+
+ loginData.montageLiveFPS = '';
}