i18n finance + controller

This commit is contained in:
Manuel Wiedenmann 2013-02-10 15:05:20 +07:00
parent 2d58054d1c
commit 8be93c33f8
13 changed files with 186 additions and 91 deletions

View file

@ -5,22 +5,22 @@
%table.table.table-striped
%thead
%tr
%th Name
%th Ende
%th Status
%th zuletzt bearbeitet von
%th= t('.name')
%th= t('.end')
%th= t('.state')
%th= t('.last_edited_by')
%th
%tbody
- @orders.each do |order|
%tr{:class => cycle("even","odd", :name => "order")}
%td= link_to truncate(order.name), new_finance_order_path(order_id: order.id)
%td=h format_time(order.ends) unless order.ends.nil?
%td= order.closed? ? "abgerechnet (#{number_to_currency order.foodcoop_result})" : "beendet"
%td= order.closed? ? t('.cleared', amount: number_to_currency(order.foodcoop_result)) : "beendet"
%td= order.updated_by.nil? ? '??' : order.updated_by.nick
%td
- unless order.closed?
= link_to "abrechnen", new_finance_order_path(order_id: order.id), class: 'btn btn-mini btn-primary'
= link_to 'direkt schließen', close_direct_finance_order_path(order),
:confirm => 'Wirklich die Bestellung schließen setzen?', :method => :put, class: 'btn btn-mini'
= link_to t('.clear'), new_finance_order_path(order_id: order.id), class: 'btn btn-mini btn-primary'
= link_to t('.close'), close_direct_finance_order_path(order),
:confirm => t('.confirm'), :method => :put, class: 'btn btn-mini'
- else
%i derzeit gibt es keine beendeten Bestellungen
%i= t('.no_closed_orders')