BR-22
Each Invoice line (BG-25) shall have an Invoiced quantity (BT-129).
Why it fails
- A line has no
cbc:InvoicedQuantity(cbc:CreditedQuantityin a credit note,ram:BilledQuantityin CII), common for lump-sum services.
How to fix it
Give every line a quantity. For a lump sum, use 1 with the unit code C62 (one) or LS (lump sum).
What the rule checks
As the rule set's publisher wrote it. The rule runs on every element the context matches, and fails where the test is false; the validator reports the line of that element.
cac:InvoiceLine | cac:CreditNoteLine
exists(cbc:InvoicedQuantity) or exists(cbc:CreditedQuantity)
Checked with EN 16931 Invoice (UBL), EN 16931 Credit Note (UBL), Croatia eRačun Invoice (UBL), Croatia eRačun Credit Note (UBL)
//ram:IncludedSupplyChainTradeLineItem
(ram:SpecifiedLineTradeDelivery/ram:BilledQuantity)
Checked with EN 16931 Invoice (CII)