2012-04-20 18:33:47 +02:00
|
|
|
= simple_form_for([:finance, @invoice]) do |f|
|
2009-01-18 17:42:51 +01:00
|
|
|
= f.hidden_field :delivery_id
|
2009-01-29 21:28:22 +01:00
|
|
|
= f.hidden_field :order_id
|
2009-01-18 17:42:51 +01:00
|
|
|
|
|
|
|
- if @invoice.delivery
|
2013-06-21 14:24:05 +02:00
|
|
|
%p= t('finance.invoices.linked', what_link: link_to(t('finance.invoices.linked_delivery'), [@invoice.supplier,@invoice.delivery])).html_safe
|
2009-01-29 21:28:22 +01:00
|
|
|
- if @invoice.order
|
2013-12-30 11:26:10 +01:00
|
|
|
%p= t('finance.invoices.linked', what_link: link_to(t('finance.invoices.linked_order'), new_finance_order_path(order_id: @invoice.order.id))).html_safe
|
2012-04-20 18:33:47 +02:00
|
|
|
|
2016-02-17 16:11:01 +01:00
|
|
|
- if @invoice.created_at
|
|
|
|
= f.input :created_at do
|
|
|
|
= format_time(@invoice.created_at)
|
|
|
|
= f.input :created_by do
|
|
|
|
= show_user(@invoice.created_by)
|
2012-04-20 18:33:47 +02:00
|
|
|
= f.association :supplier, hint: false
|
|
|
|
= f.input :number
|
2012-11-10 16:44:05 +01:00
|
|
|
= f.input :date, as: :date_picker
|
|
|
|
= f.input :paid_on, as: :date_picker
|
2012-04-20 18:33:47 +02:00
|
|
|
= f.input :amount, as: :string
|
|
|
|
= f.input :deposit, as: :string
|
|
|
|
= f.input :deposit_credit, as: :string
|
|
|
|
= f.input :note
|
2012-11-10 16:44:05 +01:00
|
|
|
.form-actions
|
|
|
|
= f.submit class: 'btn'
|
2013-04-04 02:49:52 +02:00
|
|
|
= link_to t('ui.or_cancel'), :back
|