VRBL-INV-HR-CIUS-1p0-46
Basic Info
|
Rule
|
When the Tax Category Rate is not 0, the value of the Tax Category Code must not be contained in Tax Category IDs with Zero Tax Rate [VRBL-CL-HR-ZeroTaxRate-TaxCategoryID] (prefixed by 'VRBL:HR:'). Not allowed values: VRBL:HR:HR:AE, VRBL:HR:HR:E, VRBL:HR:HR:N, VRBL:HR:HR:Z. |
|
Context
|
/ubl:Invoice/cac:TaxTotal[cbc:TaxAmount/@currencyID = ../cbc:DocumentCurrencyCode]/cac:TaxSubtotal/cac:TaxCategory/cbc:ID
|
|
Pattern
|
vrbl-invoice-hr-cius-1p0 |
|
Severity
|
fatal |
Used Template: CodeList
| Parameter |
|
Value |
| probe |
= |
.
|
| codeList |
= |
!$VRBL-HR-CIUS-Prefix:$VRBL-CL-HR-ZeroTaxRate-TaxCategoryID
|
| showValues |
= |
true
|
Implementation
(
../cbc:Percent = 0
)
or
(
not(boolean(.))
or
(
not(
substring(normalize-space(.), 1, string-length($VRBL-HR-CIUS-Prefix)) = $VRBL-HR-CIUS-Prefix
and
not(
contains(
substring-after(normalize-space(.), $VRBL-HR-CIUS-Prefix),
substring($VRBL-CL-HR-ZeroTaxRate-TaxCategoryID, 1, 1)
)
)
and
contains(
$VRBL-CL-HR-ZeroTaxRate-TaxCategoryID,
concat(
substring($VRBL-CL-HR-ZeroTaxRate-TaxCategoryID, 1, 1),
substring-after(normalize-space(.), $VRBL-HR-CIUS-Prefix),
substring($VRBL-CL-HR-ZeroTaxRate-TaxCategoryID, 1, 1)
)
)
)
)
)