2009-01-06 11:49:19 +01:00
|
|
|
%h1 Finanzbereich
|
|
|
|
.left_column{:style => 'width: 50%'}
|
2009-01-10 19:36:58 +01:00
|
|
|
.box_title
|
|
|
|
%h2 Unpaid invoices
|
|
|
|
.column_content
|
2009-01-10 22:22:16 +01:00
|
|
|
%p= link_to "Show all invoices", finance_invoices_path
|
2009-01-10 19:36:58 +01:00
|
|
|
%table.list
|
|
|
|
%thead
|
|
|
|
%tr
|
|
|
|
%th Date
|
|
|
|
%th Amount
|
|
|
|
%th Supplier
|
|
|
|
%th
|
|
|
|
%tbody
|
|
|
|
- for invoice in @unpaid_invoices
|
|
|
|
%tr{:class => cycle("even","odd", :name => "invoices")}
|
|
|
|
%td= format_date(invoice.date)
|
|
|
|
%td= number_to_currency(invoice.amount)
|
|
|
|
%td=h invoice.supplier.name
|
2009-01-10 22:22:16 +01:00
|
|
|
%td= link_to "Edit", edit_finance_invoice_path(invoice)
|
2009-01-10 19:36:58 +01:00
|
|
|
|
2009-01-06 11:49:19 +01:00
|
|
|
.box_title
|
|
|
|
%h2 letzte Überweisungen
|
|
|
|
.column_content
|
|
|
|
%p
|
2009-01-10 22:22:16 +01:00
|
|
|
= link_to "Bestellgruppen", :controller => 'finance/transactions'
|
2009-01-06 11:49:19 +01:00
|
|
|
%table.list
|
|
|
|
%thead
|
|
|
|
%tr
|
|
|
|
%th Datum
|
|
|
|
%th Gruppe
|
|
|
|
%th Notiz
|
|
|
|
%th Betrag
|
|
|
|
%tbody
|
|
|
|
- @financial_transactions.each do |ft|
|
|
|
|
%tr{:class => cycle("even","odd", :name => "financial_transaction")}
|
|
|
|
%td= format_date(ft.created_on)
|
2009-01-14 12:46:01 +01:00
|
|
|
%td= ft.ordergroup.name
|
2009-01-06 11:49:19 +01:00
|
|
|
%td{:style => "width:50%"}=h ft.note
|
|
|
|
%td{:style => "color:#{ft.amount < 0 ? 'red' : 'black'}", :class => "currency"}= number_to_currency(ft.amount)
|
|
|
|
|
|
|
|
.right_column{:style => 'width: 46%'}
|
|
|
|
.box_title
|
|
|
|
%h2 noch nicht abgerechnet
|
|
|
|
.column_content
|
2009-01-10 22:22:16 +01:00
|
|
|
%p= link_to "Bestellungsübersicht", :controller => 'finance/orders'
|
2009-01-06 11:49:19 +01:00
|
|
|
- unless @orders.empty?
|
|
|
|
%table.list
|
|
|
|
%thead
|
|
|
|
%tr
|
|
|
|
%th Name
|
|
|
|
%th Ende
|
|
|
|
%th Betrag(FC)
|
|
|
|
%th
|
|
|
|
%tbody
|
|
|
|
- @orders.each do |order|
|
|
|
|
%tr{:class => cycle("even","odd", :name => "order")}
|
|
|
|
%td= order.name
|
|
|
|
%td= format_date(order.ends)
|
|
|
|
%td{:class => "currency"}= number_to_currency(order.sumPrice("fc"))
|
|
|
|
%td= link_to "abrechnen", :action => "editOrder", :id => order
|
|
|
|
- else
|
|
|
|
Super, alles schon abgerechnet...
|