1
0
mirror of https://github.com/haiwen/seahub.git synced 2025-04-27 19:05:16 +00:00

[invitation] delete: modification (#2379)

This commit is contained in:
llj 2018-09-19 10:08:51 +08:00 committed by Daniel Pan
parent 4227689c9d
commit 3fa4a88a96

View File

@ -21,9 +21,12 @@ define([
'click .rm-invitation': 'removeInvitation'
},
removeInvitation: function() {
removeInvitation: function(e) {
var _this = this;
var $el = $(e.currentTarget);
$el.hide(); // hide the icon to avoid being clicked repeatedly
$.ajax({
url: Common.getUrl({
'name': 'invitation',
@ -37,6 +40,7 @@ define([
Common.feedback(gettext("Successfully deleted 1 item."), 'success');
},
error: function(xhr) {
$el.show();
Common.ajaxErrorHandler(xhr);
}
});