dashboard: slightly better admin notes edit handling
This commit is contained in:
@@ -141,14 +141,17 @@ angular.module('Application').controller('AppController', ['$scope', '$location'
|
||||
hasOldChecklist: false,
|
||||
|
||||
notes: {
|
||||
busy: false,
|
||||
busy: true,
|
||||
editing: false,
|
||||
content: '',
|
||||
placeholder: 'Add admin notes here...',
|
||||
|
||||
edit: function () {
|
||||
$scope.info.notes.busy = false;
|
||||
$scope.info.notes.content = $scope.app.notes;
|
||||
$scope.info.notes.editing = true;
|
||||
|
||||
setTimeout(function () { document.getElementById('adminNotesTextarea').focus(); }, 1);
|
||||
},
|
||||
|
||||
dismiss: function () {
|
||||
@@ -166,8 +169,8 @@ angular.module('Application').controller('AppController', ['$scope', '$location'
|
||||
refreshApp($scope.app.id, function (error) {
|
||||
if (error) return Client.error(error);
|
||||
|
||||
$scope.info.notes.busy = false;
|
||||
$scope.info.notes.editing = false;
|
||||
$scope.info.notes.busy = false;
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user