Skip to content
Snippets Groups Projects
Commit 3327c79c8181 authored by sand's avatar sand
Browse files

reload only validated comment tree for sub-comments instead of reloading the entire comment section

parent 1f15b0fcb614
No related branches found
No related tags found
No related merge requests found
......@@ -38,7 +38,11 @@
d = asyncRemoteExec(funcname, eid, comment, format);
d.addCallback(function () {
var rooteid = getNode('commentsectionComponent').getAttribute('cubicweb:rooteid');
reloadComponent('commentsection', rql_for_eid(rooteid), 'contentnavigation');
if (rooteid == eid){
reloadComponent('commentsection', rql_for_eid(eid), 'contentnavigation');
} else {
reloadComponent('tree', rql_for_eid(eid), 'views', 'comment'+eid);
}
});
} else { // comment cancelled, close div holding the form
var comment = jQuery('#comment' + eid + 'Slot');
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment