foodsoft/app/views/finance/invoices/show.html.haml
2016-02-24 00:39:07 +01:00

45 lines
1.3 KiB
Text

- title t('.title', number: @invoice.number)
%p
%b= heading_helper(Invoice, :created_at) + ':'
= format_time(@invoice.created_at)
%p
%b= heading_helper(Invoice, :created_by) + ':'
= show_user(@invoice.created_by)
%p
%b= heading_helper(Invoice, :supplier) + ':'
= @invoice.supplier.name
- if @invoice.delivery
%p
%b= heading_helper(Invoice, :delivery) + ':'
= t('finance.invoices.linked', what_link: link_to(t('finance.invoices.linked_delivery'), [@invoice.supplier,@invoice.delivery])).html_safe
- if @invoice.order
%p
%b= heading_helper(Invoice, :order) + ':'
= t('finance.invoices.linked', what_link: link_to(t('finance.invoices.linked_order'), @invoice.order)).html_safe
%p
%b= heading_helper(Invoice, :number) + ':'
= @invoice.number
%p
%b= heading_helper(Invoice, :date) + ':'
= @invoice.date
%p
%b= heading_helper(Invoice, :paid_on) + ':'
= @invoice.paid_on
%p
%b= heading_helper(Invoice, :amount) + ':'
= number_to_currency @invoice.amount
%p
%b= heading_helper(Invoice, :deposit) + ':'
= number_to_currency @invoice.deposit
%p
%b= heading_helper(Invoice, :deposit_credit) + ':'
= number_to_currency @invoice.deposit_credit
%p
%b= heading_helper(Invoice, :note) + ':'
=h @invoice.note
= link_to t('ui.edit'), edit_finance_invoice_path(@invoice)
= link_to t('ui.or_cancel'), finance_invoices_path