summaryrefslogtreecommitdiff
path: root/www/js
diff options
context:
space:
mode:
Diffstat (limited to 'www/js')
-rw-r--r--www/js/EventCtrl.js8
1 files changed, 8 insertions, 0 deletions
diff --git a/www/js/EventCtrl.js b/www/js/EventCtrl.js
index 4fc2e42d..5be5226a 100644
--- a/www/js/EventCtrl.js
+++ b/www/js/EventCtrl.js
@@ -810,6 +810,7 @@ angular.module('zmApp.controllers')
};
+
$scope.downloadFileToDevice = function(path, eid)
{
@@ -821,7 +822,14 @@ angular.module('zmApp.controllers')
tp = cordova.file.dataDirectory + "temp-video.mp4";
var th = true;
+
var opt = {};
+
+ if ($rootScope.basicAuthHeader) {
+ opt.headers = {"Authorization": $rootScope.basicAuthHeader};
+ NVRDataModel.debug ("download with auth options is:"+JSON.stringify(opt));
+ }
+
//path = "http://techslides.com/demos/sample-videos/small.mp4";
NVRDataModel.debug("Saving temporary video to: " + tp);