CII-SR-476
Only one AdditionalReferencedDocument AttachmentBinaryObject BT-125 is allowed with TypeCode 916.
Why it fails
- One
ram:AdditionalReferencedDocumentwithram:TypeCode916carries more than oneram:AttachmentBinaryObject.
How to fix it
Split the attachments into one ram:AdditionalReferencedDocument each.
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.
/rsm:CrossIndustryInvoice/rsm:SupplyChainTradeTransaction/ram:ApplicableHeaderTradeAgreement/ram:AdditionalReferencedDocument
normalize-space(ram:TypeCode) != '916' or count(ram:AttachmentBinaryObject) <= 1
Checked with EN 16931 Invoice (CII)
/rsm:CrossIndustryInvoice/rsm:SupplyChainTradeTransaction/ram:ApplicableHeaderTradeAgreement
count(ram:AdditionalReferencedDocument[normalize-space(ram:TypeCode) = '916']/ram:AttachmentBinaryObject) <= 1
Checked with France e-invoice (CII), XRechnung 3.0 Invoice (CII)