mirror of
https://github.com/zulip/zulip.git
synced 2025-11-13 02:17:19 +00:00
Allow users to deactivate their bots from the website.
(The back end had been in place already.) (imported from commit ec4b7b3ea39d71d86b0bdc161740e494ce1e13f7)
This commit is contained in:
@@ -163,6 +163,19 @@ $(function () {
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
$("#bots_list").on("click", "button.delete_bot", function (e) {
|
||||
var email = $(e.target).data('email');
|
||||
$.ajax({
|
||||
url: '/json/users/' + encodeURIComponent(email),
|
||||
type: 'DELETE',
|
||||
success: function () {
|
||||
var row = $(e.target).closest("li");
|
||||
row.remove();
|
||||
}
|
||||
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
}());
|
||||
|
||||
Reference in New Issue
Block a user