XV-CZ-01
In the VAT summary, TaxableAmount + TaxAmount must equal TaxInclusiveAmount (… + … is not …), in the foreign currency too (ISDOC 6.0.2, A.10).
error: the document is invalid
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.
Context
/isdoc:Invoice/isdoc:TaxTotal/isdoc:TaxSubTotal
Test
cz:same(cz:dec(isdoc:TaxableAmount) + cz:dec(isdoc:TaxAmount), cz:dec(isdoc:TaxInclusiveAmount)) and (not(isdoc:TaxableAmountCurr and isdoc:TaxAmountCurr and isdoc:TaxInclusiveAmountCurr) or cz:same(cz:dec(isdoc:TaxableAmountCurr) + cz:dec(isdoc:TaxAmountCurr), cz:dec(isdoc:TaxInclusiveAmountCurr)))
Checked with ISDOC 6.0.2