sort ordergroups in order screen and pdfs

This commit is contained in:
wvengen 2013-09-17 00:25:38 +02:00
parent 8ca95f396f
commit b11706f30a
6 changed files with 7 additions and 5 deletions

View file

@ -15,7 +15,7 @@
= 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
- for goa in order_article.group_order_articles.ordered
%tr{:class => [cycle('even', 'odd', :name => 'groups'), if goa.result == 0 then 'unavailable' end]}
%td{:style => "width:70%"}=h goa.group_order.ordergroup.name
%td= "#{goa.quantity} + #{goa.tolerance}"

View file

@ -13,7 +13,7 @@
%th= t '.unit'
%th= t '.price'
- for group_order in order.group_orders.all
- for group_order in order.group_orders.ordered
%thead
%tr
%th{:colspan => "7"}