Skip to content

Class.UblWriter

github-actions[bot] edited this page Jan 7, 2025 · 10 revisions

einvoicing / UblWriter

Class: UblWriter

Extends

Constructors

new UblWriter()

new UblWriter(): UblWriter

Returns

UblWriter

Inherited from

AbstractWriter.constructor

Methods

addressToXmlNode()

addressToXmlNode(address): object

Parameters

address

Address

Returns

object

cac:Country

cac:Country: object

cac:Country.cbc:IdentificationCode

cbc:IdentificationCode: string = address.countryCode

cbc:AdditionalStreetName

cbc:AdditionalStreetName: string

cbc:CityName

cbc:CityName: string = address.cityName

cbc:CountrySubentity

cbc:CountrySubentity: string = address.subdivision

cbc:PostalZone

cbc:PostalZone: string = address.postalZone

cbc:StreetName

cbc:StreetName: string = address.streetName

Defined in

writers/UblWriter.ts:293


allowanceChargeToXmlNode()

allowanceChargeToXmlNode(charge, currency): object

Parameters

charge

AllowanceCharge

currency

CurrencyCode

Returns

object

cac:TaxCategory

cac:TaxCategory: object

cac:TaxCategory.cac:TaxScheme

cac:TaxScheme: object

cac:TaxCategory.cac:TaxScheme.cbc:ID

cbc:ID: string = 'VAT'

cac:TaxCategory.cbc:ID

cbc:ID: string

cac:TaxCategory.cbc:Percent

cbc:Percent: string

cac:TaxCategory.cbc:TaxExemptionReason

cbc:TaxExemptionReason: string = charge.tax.taxExemptionReason

cac:TaxCategory.cbc:TaxExemptionReasonCode

cbc:TaxExemptionReasonCode: string = charge.tax.taxExemptionReasonCode

cbc:AllowanceChargeReason

cbc:AllowanceChargeReason: string = charge.reasonText

cbc:AllowanceChargeReasonCode

cbc:AllowanceChargeReasonCode: string = charge.reasonCode

cbc:Amount

cbc:Amount: object

cbc:Amount.#text

#text: string

cbc:Amount.attr_currencyID

attr_currencyID: string

cbc:BaseAmount

cbc:BaseAmount: object

cbc:BaseAmount.#text

#text: string

cbc:BaseAmount.attr_currencyID

attr_currencyID: string

cbc:ChargeIndicator

cbc:ChargeIndicator: boolean = charge.isCharge

cbc:MultiplierFactorNumeric

cbc:MultiplierFactorNumeric: string

Defined in

writers/UblWriter.ts:306


partyToXmlNode()

partyToXmlNode(party): object

Parameters

party

Party

Returns

object

cac:Contact

cac:Contact: object

cac:Contact.cbc:ElectronicMail

cbc:ElectronicMail: string = party.contact.email

cac:Contact.cbc:Name

cbc:Name: string = party.contact.name

cac:Contact.cbc:Telephone

cbc:Telephone: string = party.contact.phone

cac:PartyIdentification

cac:PartyIdentification: object[]

cac:PartyLegalEntity

cac:PartyLegalEntity: object

cac:PartyLegalEntity.cbc:CompanyID

cbc:CompanyID: object

cac:PartyLegalEntity.cbc:CompanyID.#text

#text: string

cac:PartyLegalEntity.cbc:CompanyLegalForm

cbc:CompanyLegalForm: string = party.companyLegalForm

cac:PartyLegalEntity.cbc:RegistrationName

cbc:RegistrationName: string = party.legalName

cac:PartyName

cac:PartyName: object

cac:PartyName.cbc:Name

cbc:Name: string = party.tradingName

cac:PartyTaxScheme

cac:PartyTaxScheme: object[]

cac:PostalAddress

cac:PostalAddress: object

cac:PostalAddress.cac:Country

cac:Country: object

cac:PostalAddress.cac:Country.cbc:IdentificationCode

cbc:IdentificationCode: string = address.countryCode

cac:PostalAddress.cbc:AdditionalStreetName

cbc:AdditionalStreetName: string

cac:PostalAddress.cbc:CityName

cbc:CityName: string = address.cityName

cac:PostalAddress.cbc:CountrySubentity

cbc:CountrySubentity: string = address.subdivision

cac:PostalAddress.cbc:PostalZone

cbc:PostalZone: string = address.postalZone

cac:PostalAddress.cbc:StreetName

cbc:StreetName: string = address.streetName

cbc:EndpointID

cbc:EndpointID: object

cbc:EndpointID.#text

#text: string

Defined in

writers/UblWriter.ts:264


write()

write(document): string

Parameters

document

Document

Returns

string

Overrides

AbstractWriter.write

Defined in

writers/UblWriter.ts:19


writeToFile()

writeToFile(document, filename): Promise<void>

Parameters

document

Document

filename

string

Returns

Promise<void>

Inherited from

AbstractWriter.writeToFile

Defined in

writers/AbstractWriter.ts:14

Clone this wiki locally