add receive screen, quantities for model, redistribution

This commit is contained in:
wvengen 2013-11-25 13:48:54 +01:00
parent ed9a6cca39
commit bd1b932775
17 changed files with 365 additions and 49 deletions

View file

@ -0,0 +1,9 @@
# :encoding:utf-8:
module Finance::ReceiveHelper
# TODO currently duplicate a bit of DeliveriesHelper.articles_for_select2
def articles_for_select2(supplier)
supplier.articles.undeleted.reorder('articles.name ASC').map do |a|
{:id => a.id, :text => "#{a.name} (#{a.unit_quantity}#{a.unit})"}
end
end
end