Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Deserialization of CreditNoteType #42

Copy link
Copy link
@NickAelbrecht

Description

@NickAelbrecht
Issue body actions

Hi

We're currently working on parsing peppol invoices and credit notes (peppol bis 3.0 format), and using UblSharp for this.
For invoices, everything works correctly but the for credit notes we ran into a weird issue.

Official example: https://github.com/OpenPEPPOL/peppol-bis-invoice-3/blob/master/rules/examples/base-creditnote-correction.xml

Parsing code:

            var xmlStream = new MemoryStream(source);
            var ubl = UblDocument.Load<CreditNoteType>(xmlStream);

Issue:
When parsing the file exactly like that, the deserialization doesn't seem correct and almost all of the data is 'null' (eg. CustomerParty.Party.PartyLegalEntity, CustomerParty.Party.PartyTaxScheme, etc, etc,..)

Weird:
When placing the BillingReference to the bottom of the XML (just above the closing CreditNote tag), the deserialization works correctly.

Someone else that noticed this? Any workarounds? Something else that isn't correctly set up maybe?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      Morty Proxy This is a proxified and sanitized view of the page, visit original site.