XV-CZ-02

In the VAT summary, AlreadyClaimedTaxableAmount + AlreadyClaimedTaxAmount must equal AlreadyClaimedTaxInclusiveAmount, 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:AlreadyClaimedTaxableAmount) + cz:dec(isdoc:AlreadyClaimedTaxAmount), cz:dec(isdoc:AlreadyClaimedTaxInclusiveAmount)) and (not(isdoc:AlreadyClaimedTaxableAmountCurr and isdoc:AlreadyClaimedTaxAmountCurr and isdoc:AlreadyClaimedTaxInclusiveAmountCurr) or cz:same(cz:dec(isdoc:AlreadyClaimedTaxableAmountCurr) + cz:dec(isdoc:AlreadyClaimedTaxAmountCurr), cz:dec(isdoc:AlreadyClaimedTaxInclusiveAmountCurr)))

Checked with ISDOC 6.0.2