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.
body_tracking/app/views/ingredients/_new_form.html.erb
cryptogopher a4ec6a0c12 Added Ingredient editing
Improved Ingredient to match Measurement functionality
2019-12-30 23:45:59 +01:00

19 lines
516 B
Plaintext

<h2><%= t ".heading_new_ingredient" %></h2>
<%= labelled_form_for @ingredient,
url: project_ingredients_path(@project, view_mode: current_view),
remote: true,
html: {id: 'new-ingredient-form', name: 'new-ingredient-form'} do |f| %>
<%= render partial: 'ingredients/form', locals: {f: f} %>
<div class="tabular">
<p>
<%= submit_tag l(:button_create) %>
<%= link_to l(:button_cancel), "#",
onclick: '$("#new-ingredient").empty(); return false;' %>
</p>
</div>
<% end %>
<hr>