1
0
This repository has been archived on 2023-12-07. You can view files and clone it, but cannot push or open issues or pull requests.
2020-04-20 22:56:05 +02:00

8 lines
392 B
Plaintext

$('tr[id=meal-<%= @meal.id %>]').nextUntil('tr.primary, tr.date', ':not(.ingredient)').remove();
var columns = $('table > tbody > tr.ingredient > td').length;
$('tr[id=meal-<%= @meal.id %>]').nextUntil('tr.primary, tr.date').addBack().last().after(
'<tr><td class="form" colspan="'+columns+'"><div id="edit-meal">' +
'<%= j render partial: 'meals/edit_form' %>' +
'</div></td></tr>'
);