diff options
| -rw-r--r-- | www/js/EventCtrl.js | 5 | ||||
| -rw-r--r-- | www/lang/locale-en.json | 2 | ||||
| -rw-r--r-- | www/templates/events.html | 4 |
3 files changed, 8 insertions, 3 deletions
diff --git a/www/js/EventCtrl.js b/www/js/EventCtrl.js index a3958501..3af0de79 100644 --- a/www/js/EventCtrl.js +++ b/www/js/EventCtrl.js @@ -37,7 +37,7 @@ angular.module('zmApp.controllers') }) -.controller('zmApp.EventCtrl', ['$scope', '$rootScope', 'zm', 'NVRDataModel', 'message', '$ionicSideMenuDelegate', '$timeout', '$interval', '$ionicModal', '$ionicLoading', '$http', '$state', '$stateParams', '$ionicHistory', '$ionicScrollDelegate', '$ionicPlatform', '$ionicSlideBoxDelegate', '$ionicPosition', '$ionicPopover', '$ionicPopup', 'EventServer', '$sce', '$cordovaBadge', '$cordovaLocalNotification', '$q', 'carouselUtils', '$translate', '$cordovaFileTransfer', '$cordovaFile', function($scope, $rootScope, zm, NVRDataModel, message, $ionicSideMenuDelegate, $timeout, $interval, $ionicModal, $ionicLoading, $http, $state, $stateParams, $ionicHistory, $ionicScrollDelegate, $ionicPlatform, $ionicSlideBoxDelegate, $ionicPosition, $ionicPopover, $ionicPopup, EventServer, $sce, $cordovaBadge, $cordovaLocalNotification, $q, carouselUtils, $translate, $cordovaFileTransfer, $cordovaFile) +.controller('zmApp.EventCtrl', ['$scope', '$rootScope', 'zm', 'NVRDataModel', 'message', '$ionicSideMenuDelegate', '$timeout', '$interval', '$ionicModal', '$ionicLoading', '$http', '$state', '$stateParams', '$ionicHistory', '$ionicScrollDelegate', '$ionicPlatform', '$ionicSlideBoxDelegate', '$ionicPosition', '$ionicPopover', '$ionicPopup', 'EventServer', '$sce', '$cordovaBadge', '$cordovaLocalNotification', '$q', 'carouselUtils', '$translate', '$cordovaFileTransfer', '$cordovaFile', '$ionicListDelegate',function($scope, $rootScope, zm, NVRDataModel, message, $ionicSideMenuDelegate, $timeout, $interval, $ionicModal, $ionicLoading, $http, $state, $stateParams, $ionicHistory, $ionicScrollDelegate, $ionicPlatform, $ionicSlideBoxDelegate, $ionicPosition, $ionicPopover, $ionicPopup, EventServer, $sce, $cordovaBadge, $cordovaLocalNotification, $q, carouselUtils, $translate, $cordovaFileTransfer, $cordovaFile, $ionicListDelegate) { // events in last 5 minutes @@ -1559,6 +1559,9 @@ angular.module('zmApp.controllers') $scope.archiveUnarchiveEvent = function (ndx,eid) { //https://server/zm/api/events/11902.json -XPUT -d"Event[Archived]=1" + // + $ionicListDelegate.closeOptionButtons(); + NVRDataModel.debug ("Archiving request for EID="+eid); var loginData = NVRDataModel.getLogin(); var apiArchive = loginData.apiurl + "/events/" + eid + ".json"; diff --git a/www/lang/locale-en.json b/www/lang/locale-en.json index 77a33f8f..e214a366 100644 --- a/www/lang/locale-en.json +++ b/www/lang/locale-en.json @@ -119,6 +119,7 @@ "kFilterOn" :"Filter On", "kFilterSettings" :"Filter Settings", "kFitScreen" :"fit screen", + "kFlag" :"Flag", "kFootage" :"Footage", "kForceAlarmConfirm" :"Are you sure you want to force an alarm for Monitor:", "kForceImagePath" :"Force events to use file path", @@ -344,6 +345,7 @@ "kToastSearchingPage" :"searching page ", "kTrying" :"trying", "kType" :"type", + "kUnflag" : "Unflag", "kUnknown" :"(unknown)", "kUpdateTimeline" :"dynamic updates", "kUseEventServer" :"Use event server", diff --git a/www/templates/events.html b/www/templates/events.html index d76d4083..cb6809f3 100644 --- a/www/templates/events.html +++ b/www/templates/events.html @@ -188,9 +188,9 @@ </ion-delete-button> - <ion-option-button ng-if="event.Event.Archived == 1" class="button-balanced" ng-click= "archiveUnarchiveEvent($index,event.Event.Id)">Unflag</ion-option-button> + <ion-option-button ng-if="event.Event.Archived == 1" class="button-balanced" ng-click= "archiveUnarchiveEvent($index,event.Event.Id)">{{'kUnflag' | translate}}</ion-option-button> - <ion-option-button ng-if="event.Event.Archived == 0" class="button-assertive" ng-click="archiveUnarchiveEvent($index, event.Event.Id)" >Flag</ion-option-button> + <ion-option-button ng-if="event.Event.Archived == 0" class="button-assertive" ng-click="archiveUnarchiveEvent($index, event.Event.Id)" >{{'kFlag' | translate}}</ion-option-button> <!-- hack to make sure swipe left displays well if there is no content and our list height is set |
