Method: ISDOCOutputBuilder#build_taxed_deposits

Defined in:
lib/isdoc_output_builder.rb

#build_taxed_deposits(xml, details) ⇒ Object



199
200
201
202
203
204
205
206
207
208
209
210
211
212
# File 'lib/isdoc_output_builder.rb', line 199

def build_taxed_deposits(xml, details)
  for detail in details
    xml.encoded_tag! :TaxedDeposit do |taxed_deposit|
      taxed_deposit.encoded_tag! :ID, detail[:id]
      taxed_deposit.encoded_tag! :VariableSymbol, detail[:variable_symbol]
      taxed_deposit.encoded_tag! :TaxableDepositAmount, detail[:taxable_deposit_amount]
      taxed_deposit.encoded_tag! :TaxInclusiveDepositAmount, detail[:tax_inclusive_deposit_amount]
      taxed_deposit.encoded_tag! :ClassifiedTaxCategory do |classified_tax_category|
        classified_tax_category.encoded_tag! :Percent, detail[:tax_percent]
        classified_tax_category.encoded_tag! :VATCalculationMethod, detail[:vat_calculation_method]
      end
    end
  end
end