%
form_wrap_id = dom_id(resource, 'list_edit')
html = render('table', collection: [resource])[/
]+>.*<\/tr>/m].html_safe
%>
$('#<%= form_wrap_id %>').remove();
$('#<%= dom_id(resource, 'list') %>').replaceWith('<%= j html %>');
$('#<%= dom_id(resource, 'list') %>').addClass('success').scrollToEl()