From 34bbd398299df488422f1d993a47593045f8c8d1 Mon Sep 17 00:00:00 2001 From: JeanMichel FRANCOIS Date: Wed, 21 Aug 2013 11:07:48 +0200 Subject: [PATCH] fix: add form serialized data to the delete comment ajax form submit Even if in fresh Plone there is no data, I'm in a case where I'm adding 'ajax' marker in the form to not render all the page (which is the case here) and the render is not used at all except if the action do not happens in ajax. --- CHANGES.rst | 2 ++ plone/app/discussion/browser/javascripts/comments.js | 1 + 2 files changed, 3 insertions(+) diff --git a/CHANGES.rst b/CHANGES.rst index 41f39d6..5d9f16f 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -7,6 +7,8 @@ Changelog - Rename CHANGES.txt to CHANGES.rst. [timo] +- Fix ajax form submit for delete comment action: add 'data' to the request. + [toutpt] 2.2.8 (2013-08-20) ------------------ diff --git a/plone/app/discussion/browser/javascripts/comments.js b/plone/app/discussion/browser/javascripts/comments.js index 9678c6d..25accda 100644 --- a/plone/app/discussion/browser/javascripts/comments.js +++ b/plone/app/discussion/browser/javascripts/comments.js @@ -177,6 +177,7 @@ $.ajax({ type: 'POST', url: form_url, + data: data, context: $(trigger).parents(".comment"), success: function (data) { var comment = $(this);