extension css and logic updates
This commit is contained in:
@@ -210,7 +210,7 @@ angular.module('app.frontend')
|
||||
this.note.setDirty(true);
|
||||
|
||||
apiController.sync(function(response){
|
||||
if(!response) {
|
||||
if(response && response.error) {
|
||||
this.note.presentation_name = original;
|
||||
this.url.token = original;
|
||||
alert("This URL is not available.");
|
||||
|
||||
@@ -32,9 +32,11 @@ angular.module('app.frontend')
|
||||
this.showAccountMenu = !this.showAccountMenu;
|
||||
this.showFaq = false;
|
||||
this.showNewPasswordForm = false;
|
||||
this.showExtensionsMenu = false;
|
||||
}
|
||||
|
||||
this.toggleExtensions = function() {
|
||||
this.showAccountMenu = false;
|
||||
this.showExtensionsMenu = !this.showExtensionsMenu;
|
||||
}
|
||||
|
||||
@@ -57,7 +59,13 @@ angular.module('app.frontend')
|
||||
action.running = true;
|
||||
extensionManager.executeAction(action, extension, null, function(response){
|
||||
action.running = false;
|
||||
apiController.sync(null);
|
||||
if(response && response.error) {
|
||||
action.error = true;
|
||||
alert("There was an error performing this action. Please try again.");
|
||||
} else {
|
||||
action.error = false;
|
||||
apiController.sync(null);
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
@@ -118,7 +126,7 @@ angular.module('app.frontend')
|
||||
$timeout(function(){
|
||||
this.isRefreshing = false;
|
||||
}.bind(this), 200)
|
||||
if(!response) {
|
||||
if(response && response.error) {
|
||||
alert("There was an error syncing. Please try again. If all else fails, log out and log back in.");
|
||||
} else {
|
||||
this.syncUpdated();
|
||||
|
||||
@@ -113,11 +113,15 @@ angular.module('app.frontend')
|
||||
$scope.saveNote = function(note, callback) {
|
||||
note.setDirty(true);
|
||||
|
||||
apiController.sync(function(){
|
||||
note.hasChanges = false;
|
||||
|
||||
if(callback) {
|
||||
callback(true);
|
||||
apiController.sync(function(response){
|
||||
if(response && response.error) {
|
||||
alert("There was an error saving your note. Please try again.");
|
||||
callback(false);
|
||||
} else {
|
||||
note.hasChanges = false;
|
||||
if(callback) {
|
||||
callback(true);
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user