Class: SEPA::Builders::DirectDebit::PaymentInformation

Inherits:
Stage
  • Object
show all
Defined in:
lib/sepa_rator/builders/direct_debit/payment_information.rb

Instance Method Summary collapse

Methods inherited from Stage

call, #initialize

Constructor Details

This class inherits a constructor from SEPA::Builders::Stage

Instance Method Details

#callObject



7
8
9
10
11
12
13
14
15
16
17
# File 'lib/sepa_rator/builders/direct_debit/payment_information.rb', line 7

def call
  message.grouped_transactions.each do |group, transactions|
    builder.PmtInf do
      emit_header(group, transactions)
      emit_payment_type_information(group)
      emit_creditor_info(group)
      emit_creditor_scheme_identification(group)
      transactions.each { |transaction| emit_transaction(transaction, group) }
    end
  end
end