%p %b Gruppenbestellungen: = @order.group_order_results.size - for groupOrderResult in @order.group_order_results %p %table{:style => "width:40em"}[groupOrderResult] %thead %tr %th{:colspan => "6"}= groupOrderResult.group_name %tbody - total = 0 - for result in groupOrderResult.group_order_article_results - price = result.order_article_result.fc_price - quantity = result.quantity - subTotal = price * quantity - total += subTotal %tr{:class => cycle('even', 'odd', :name => 'article')} %td= result.order_article_result.name %td= quantity %td{:class => "currency"}= number_to_currency(price) %td= result.order_article_result.unit_quantity %td= result.order_article_result.unit %td= number_to_currency(subTotal) %tfoot %tr{:class => cycle('even', 'odd', :name => 'article')} %td{:colspan => "5"} Summe %td %b= number_to_currency(total) - reset_cycle("article")