Class: SunatInvoice::Customer

Inherits:
Tributer show all
Defined in:
lib/sunat_invoice/customer.rb

Instance Attribute Summary

Attributes inherited from Tributer

#country_code, #department, #district, #document_type, #name, #province, #ruc, #street, #ubigeo, #zone

Instance Method Summary collapse

Methods inherited from Model

#initialize

Constructor Details

This class inherits a constructor from SunatInvoice::Model

Instance Method Details

#info(xml) ⇒ Object



6
7
8
9
10
11
12
13
14
15
16
# File 'lib/sunat_invoice/customer.rb', line 6

def info(xml)
  xml['cac'].AccountingCustomerParty do
    xml['cbc'].CustomerAssignedAccountID @ruc
    xml['cbc'].AdditionalAccountID @document_type
    xml['cac'].Party do
      xml['cac'].PartyLegalEntity do
        xml['cbc'].RegistrationName @name
      end
    end
  end
end