tap/app/views/orders/new.html.erb
2015-02-19 18:12:57 +01:00

15 lines
440 B
Text

<h3>Order for <%= @user.nickname %> (Huidige schuld: <%= euro(@user.balance) %>)</h3>
<div class="row">
<%= f_form_for [@user, @order] do |f| %>
<%= f.error_messages %>
<div class="col-md-12">
<%= f.fields_for :order_items do |op_field| %>
<%= render op_field.object, f: op_field, product: op_field.object.product %>
<% end %>
</div>
<%= render 'order_items/total_price', f: f %>
<% end %>
</div>