Skip to content

Supports prefixed XML roots in PINT A-NZ import#41

Open
AndriusAndrulevicius wants to merge 4 commits into
mainfrom
dev/aan/ubl-namespaces-issue
Open

Supports prefixed XML roots in PINT A-NZ import#41
AndriusAndrulevicius wants to merge 4 commits into
mainfrom
dev/aan/ubl-namespaces-issue

Conversation

@AndriusAndrulevicius

Copy link
Copy Markdown
Collaborator

Enhances the PINT A-NZ E-document import process to correctly parse XML documents where the root element includes a namespace prefix (e.g., ``). Previously, the parser assumed a non-prefixed root, leading to failures with such documents.

The solution modifies the PINT A-NZ Import codeunit to:

  • Dynamically capture the full XML root path, including any namespace prefixes.
  • Utilize this dynamic root path for all subsequent XML node lookups, ensuring accurate data extraction regardless of the root element's prefix.

Adds dedicated test cases to validate the parsing of both standard and namespace-prefixed root elements, confirming the improved robustness of the import logic.

Ensures invoice import correctly handles XML documents with namespace-prefixed root elements, improving robustness against varying XML structures.

Adds targeted tests to verify parsing of both standard and namespace-prefixed root elements, reducing risk of import failures with valid documents.
Introduces two example invoice XML documents for PINT A-NZ with and without prefixed namespaces to support testing and validation scenarios. Enables broader coverage for namespace handling in invoice processing.
@AndriusAndrulevicius AndriusAndrulevicius marked this pull request as ready for review March 10, 2026 09:57
Comment thread Apps/APAC/EDocumentFormats/PINT A-NZ/app/src/Core/PINTANZImport.Codeunit.al Outdated
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants