1
0
mirror of https://github.com/haiwen/seahub.git synced 2025-08-31 22:54:11 +00:00

[org lib] modified 'unshare'

This commit is contained in:
llj
2015-04-22 15:57:53 +08:00
parent b00d29c8e2
commit 7ce56b26a8

View File

@@ -33,8 +33,9 @@ define([
this.$el.removeClass('hl').find('.op-icon').addClass('vh');
},
removeShare: function(e) {
removeShare: function() {
var el = this.$el;
var lib_name = this.model.get('name');
Common.ajaxGet({
get_url: Common.getUrl({
name: 'ajax_unset_inner_pub_repo',
@@ -45,9 +46,12 @@ define([
},
after_op_success: function () {
el.remove();
Common.feedback(gettext('Success'), 'success', Common.SUCCESS_TIMOUT);
var msg = gettext('Successfully unshared {placeholder}').replace('{placeholder}', '<span class="op-target">' + Common.HTMLescape(lib_name) + '</span>');
Common.feedback(msg, 'success', Common.SUCCESS_TIMOUT);
},
after_op_error: Common.ajaxErrorHandler
after_op_error: function(xhr) {
Common.ajaxErrorHandler(xhr);
}
});
}