diff --git a/src/js/controllers/remindersInboxCtrl.js b/src/js/controllers/remindersInboxCtrl.js index e19ac22b92..fba10b90fb 100644 --- a/src/js/controllers/remindersInboxCtrl.js +++ b/src/js/controllers/remindersInboxCtrl.js @@ -75,6 +75,15 @@ angular.module('starter').controller('RemindersInboxCtrl', ["$scope", "$state", } autoRefresh(); }); + $scope.$on('$ionicView.beforeLeave', function(){ + qmLog.debug('RemindersInboxCtrl beforeLeave'); + qm.notifications.post(); + }); + $scope.$on('$ionicView.afterLeave', function(){ + qmLog.debug('RemindersInboxCtrl afterLeave'); + $rootScope.hideHomeButton = false; + $rootScope.hideBackButton = false; + }); function readHelpCards(helpCard){ if(!qm.speech.getSpeechEnabled()){ return; @@ -101,11 +110,7 @@ angular.module('starter').controller('RemindersInboxCtrl', ["$scope", "$state", } }, 30 * 60 * 1000); } - $scope.$on('$ionicView.afterLeave', function(){ - qmLog.debug('RemindersInboxCtrl afterLeave', null); - $rootScope.hideHomeButton = false; - $rootScope.hideBackButton = false; - }); + var setPageTitle = function(){ if(getVariableCategoryName() === 'Treatments'){ $scope.state.title = 'Overdue Meds'; @@ -278,11 +283,8 @@ angular.module('starter').controller('RemindersInboxCtrl', ["$scope", "$state", refreshIfRunningOutOfNotifications(); return n; }; - $scope.track = function(n, value, $ev, trackAll){ // Keep trackAll param because it's used in templates/items/notification-item.html + $scope.track = function(n, value, $ev){ // Keep trackAll param because it's used in templates/items/notification-item.html if(isGhostClick($ev)){return false;} - if(trackAll){ - return $scope.trackAll(n, value, $ev); - } n.action = 'track'; n.modifiedValue = value; var valueUnit = qm.stringHelper.formatValueUnitDisplayText(n.modifiedValue + ' ' + n.unitAbbreviatedName); diff --git a/src/templates/items/notification-value-input-buttons.html b/src/templates/items/notification-value-input-buttons.html index 8a142d9cc5..e2ef88f9a9 100644 --- a/src/templates/items/notification-value-input-buttons.html +++ b/src/templates/items/notification-value-input-buttons.html @@ -11,7 +11,7 @@ @@ -23,7 +23,7 @@ @@ -35,7 +35,7 @@ @@ -48,13 +48,13 @@