Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <h2>Editing product</h2>
- <%= error_messages_for :product %>
- <% form_for(@product) do |f| %>
- <p>
- <b>Kind of Product</b><br />
- <%= f.text_field :kind %>
- </p>
- <p>
- <b>Description</b><br />
- <%= f.text_field :description %>
- </p>
- <p>
- <b>Price</b><br />
- <% fields_for "product[line_item_attributes][]", @product.line_item do |lif| %>
- <%= lif.text_field :price %>
- <% end %>
- </p>
- <p>
- <%= f.submit "Update" %>
- </p>
- <% end %>
- <%= link_to 'Show', @product %> |
- <%= link_to 'Back', products_path %>
Add Comment
Please, Sign In to add comment