PintLint

Rules / IBR-023

IBR-023 error

An Invoice line

An Invoice line (ibg-25) must have an Invoiced quantity unit of measure code (ibt-130).

Fails

<cac:InvoiceLine>
  <!-- @unitCode or @unitCode missing -->
</cac:InvoiceLine>

Fix

Add @unitCode or @unitCode.

Schematron
Context
cac:InvoiceLine | cac:CreditNoteLine
Test
exists(cbc:InvoicedQuantity/@unitCode) or exists(cbc:CreditedQuantity/@unitCode)

Official text: An Invoice line (ibg-25) MUST have an Invoiced quantity unit of measure code (ibt-130).

Official · PINT shared rules. Severity: error. Runs on UBL XML and on JSON.

Check an invoice