foodsoft/app/views/shared/_articles_by_articles.html.haml
2009-02-03 21:14:48 +01:00

26 lines
No EOL
1,017 B
Text

.legend
%table.legend{:style => "margin-bottom:1em"}
%tr
%th{:colspan => '3'} Legende
%tr
%th{:style => 'width:70%'} Bestellgruppe
%th Bestellt
%th Bekommen
%th Gesamtpreis
- for order_article in order.order_articles.ordered.all(:include => [:article, :article_price])
%table{:style => "margin-bottom:1em"}
%thead
%tr
%th{:colspan => "4"}
= order_article.article.name
= "(#{order_article.article.unit} | #{order_article.price.unit_quantity} | #{number_to_currency(order_article.price.gross_price)})"
%tbody
- for goa in order_article.group_order_articles
%tr{:class => cycle('even', 'odd', :name => 'groups')}
%td{:style => "width:70%"}=h goa.group_order.ordergroup.name
%td= "#{goa.quantity} (#{goa.tolerance})"
%td
%b= "#{goa.quantity_result} + #{goa.tolerance_result}"
%td= number_to_currency(order_article.price.fc_price * goa.quantity)
- reset_cycle('groups')