Nicolas Bally 27d7568a83 comments
2015-04-13 15:51:41 +02:00

10 lines
297 B
Plaintext

$("#comment_form").remove();
<% if @comment.parent_id == nil %>
$('#comments').append("<%= escape_javascript(render(:partial => "form"))%>");
<% else %>
$('#comment_<%= @comment.parent_id %>').children(".child_comments").append("<%= escape_javascript(render(:partial => "form"))%>");
<% end %>