app/services/distribution_itemized_breakdown_service.rb
#
# Initializes the DistributionItemizedBreakdownService whoms
# purpose to construct a itemized breakdown of items distributed
# and what is left on-hand currently (at the time of running)
#
# @param organization [Organization]
# @param distribution_ids [Array<Integer>]
# @return [DistributionItemizedBreakdownService]
Initializes the DistributionItemizedBreakdownService whoms
purpose to construct a itemized breakdown of items distributed
and what is left on-hand currently (at the time of running)
Initializes the DistributionItemizedBreakdownService whoms purpose to construct a itemized breakdown of items distributed and what is left on - hand currently ( at the time of running )
def convert_to_csv(items_distributed_data)
    CSV.generate do |csv|
      csv << ["Item", "Total Distribution", "Total On Hand"]
      items_distributed_data.each do |item|
        csv << [item[:name], item[:distributed], item[:current_onhand]]
      end
    end
  end
def convert_to_csv ( items_distributed_data ) CSV . generate do | csv | csv << [ "Item" , "Total Distribution" , "Total On Hand" ] items_distributed_data . each do | item | csv << [ item [ :name ] , item [ :distributed ] , item [ :current_onhand ] ] end end end
Initializes the DistributionItemizedBreakdownService whoms
purpose to construct a itemized breakdown of items distributed
and what is left on-hand currently (at the time of running)
Initializes the DistributionItemizedBreakdownService whoms purpose to construct a itemized breakdown of items distributed and what is left on - hand currently ( at the time of running )
None
DistributionItemizedBreakdownService
items_distributed_data
<not_specific>
<not_specific>
None