From e635bf9b5d9c9e3c8f5e3607b4b0fe01d32478cf Mon Sep 17 00:00:00 2001 From: pliablepixels Date: Wed, 24 Feb 2016 10:14:53 -0500 Subject: moved loading to after frames are retrieved Former-commit-id: bbe3d24f3faa7a9aca0e1a02d523b16e16d87233 --- www/js/EventModalCtrl.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'www') diff --git a/www/js/EventModalCtrl.js b/www/js/EventModalCtrl.js index 651b5c36..19470fe0 100644 --- a/www/js/EventModalCtrl.js +++ b/www/js/EventModalCtrl.js @@ -373,7 +373,7 @@ angular.module('zmApp.controllers').controller('EventModalCtrl', ['$scope', '$ro sendCommand('1',$scope.connKey). then (function (resp) { - $ionicLoading.hide(); + // console.log ("PAUSE ANSWER IS " + JSON.stringify(resp)); $scope.currentProgress = resp.data.status.progress; // console.log ("STEP 0 progress is " + $scope.currentProgress); @@ -383,6 +383,7 @@ angular.module('zmApp.controllers').controller('EventModalCtrl', ['$scope', '$ro $http.get(apiurl) .then (function (success) { + var event = success.data.event; event.Event.BasePath = computeBasePath(event); @@ -417,11 +418,14 @@ angular.module('zmApp.controllers').controller('EventModalCtrl', ['$scope', '$ro }); } // console.log ("STEP 2 : calling Save Event To Phone"); + $ionicLoading.hide(); saveEventImageToPhone(); + }, function (err) { + $ionicLoading.hide(); ZMDataModel.zmLog ("snapshot API Error: Could not get frames " + JSON.stringify(err)); $ionicLoading.show({ -- cgit v1.2.3