Fixed gug in startpage.

This commit is contained in:
Benjamin Meichsner 2009-02-01 21:08:04 +01:00
parent 80947b0059
commit eedee9f070

View file

@ -37,31 +37,32 @@
.column_content .column_content
= render :partial => 'messages/messages', :locals => { :subject_length => 110 } = render :partial => 'messages/messages', :locals => { :subject_length => 110 }
// Ordergroup overview - if @ordergroup
.box_title // Ordergroup overview
%h2=_ "My ordergroup" .box_title
.column_content %h2=_ "My ordergroup"
%p .column_content
%b= @ordergroup.name %p
| %b= @ordergroup.name
=_ "Account balance:" |
= number_to_currency(@ordergroup.account_balance) =_ "Account balance:"
%span{:style => "color:grey"} = number_to_currency(@ordergroup.account_balance)
(zuletzt aktualisiert vor %span{:style => "color:grey"}
= distance_of_time_in_words(Time.now, @ordergroup.account_updated) + ")" (zuletzt aktualisiert vor
%h3=_ "Last transactions" = distance_of_time_in_words(Time.now, @ordergroup.account_updated) + ")"
%table %h3=_ "Last transactions"
%tr %table
%th=_ "When" %tr
%th=_ "Who" %th=_ "When"
%th=_ "Note" %th=_ "Who"
%th=_ "Amount" %th=_ "Note"
- for ft in @financial_transactions %th=_ "Amount"
%tr{:class => cycle('even','odd')} - for ft in @financial_transactions
%td= format_time(ft.created_on) %tr{:class => cycle('even','odd')}
%td= h(ft.user.nil? ? '?' : ft.user.nick) %td= format_time(ft.created_on)
%td= h(ft.note) %td= h(ft.user.nil? ? '?' : ft.user.nick)
- color = ft.amount < 0 ? 'red' : 'black' %td= h(ft.note)
%td{:style => "color:#{color}; width:5em", :class => "currency"}= number_to_currency(ft.amount) - color = ft.amount < 0 ? 'red' : 'black'
%br/ %td{:style => "color:#{color}; width:5em", :class => "currency"}= number_to_currency(ft.amount)
= link_to _("more ..."), :action => "myOrdergroup" %br/
= link_to _("more ..."), :action => "myOrdergroup"