New invoice

<% form_for([:finance, @invoice]) do |f| %> <%= f.error_messages %>

<%= f.label :supplier_id %>
<%= f.select :supplier_id, Supplier.all.collect { |s| [s.name, s.id] } %>

<%= f.label :number %>
<%= f.text_field :number %>

<%= f.label :date %>
<%= f.date_select :date %>

<%= f.label :paid_on %>
<%= f.date_select :paid_on, :include_blank => true %>

<%= f.label :amount %>
<%= f.text_field :amount %>

<%= f.label :note %>
<%= f.text_area :note %>

<%= f.submit "Create" %>

<% end %> <%= link_to 'Back', finance_invoices_path %>