Make ajax call for delete comment button work for comment replies.
svn path=/plone.app.discussion/trunk/; revision=40853
This commit is contained in:
parent
926e4f6b8e
commit
14e2600a79
@ -169,14 +169,15 @@
|
||||
var form = $(this).parents("form");
|
||||
var data = $(form).serialize();
|
||||
var form_url = $(form).attr("action");
|
||||
var comment_div = form.parent().parent();
|
||||
$.ajax({
|
||||
type:'POST',
|
||||
url:form_url,
|
||||
context: $(trigger).parents(".comment"),
|
||||
success: function(data) {
|
||||
if($(".discussion .comment").length == 1) {
|
||||
$(".discussion").fadeOut('fast', function() {
|
||||
$(".discussion").remove();
|
||||
comment_div.fadeOut('fast', function() {
|
||||
comment_div.remove();
|
||||
});
|
||||
}
|
||||
else {
|
||||
|
Loading…
Reference in New Issue
Block a user