mirror of
https://github.com/ansible/awx.git
synced 2026-02-18 11:40:05 -03:30
Merge pull request #3036 from mabashian/working-indicator-on-toggle
Show working... spinner when toggling on/off notifications
This commit is contained in:
@@ -36,6 +36,8 @@ export default ['Wait', 'GetBasePath', 'ProcessErrors', 'Rest',
|
|||||||
disassociate: 1
|
disassociate: 1
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
// Show the working spinner
|
||||||
|
Wait('start');
|
||||||
Rest.setUrl(url);
|
Rest.setUrl(url);
|
||||||
Rest.post(params)
|
Rest.post(params)
|
||||||
.success( function(data) {
|
.success( function(data) {
|
||||||
@@ -43,9 +45,8 @@ export default ['Wait', 'GetBasePath', 'ProcessErrors', 'Rest',
|
|||||||
scope.$emit(callback, data.id);
|
scope.$emit(callback, data.id);
|
||||||
notifier[column] = !notifier[column];
|
notifier[column] = !notifier[column];
|
||||||
}
|
}
|
||||||
else {
|
// Hide the working spinner
|
||||||
Wait('stop');
|
Wait('stop');
|
||||||
}
|
|
||||||
})
|
})
|
||||||
.error( function(data, status) {
|
.error( function(data, status) {
|
||||||
ProcessErrors(scope, data, status, null, { hdr: 'Error!',
|
ProcessErrors(scope, data, status, null, { hdr: 'Error!',
|
||||||
|
|||||||
Reference in New Issue
Block a user