VRBL-INV-SA-1p2-96

Basic Info

Rule All currency ID attributes in the Legal Monetary Total Group must have the same value as the Document Currency Code.
Context /ubl:Invoice/cac:LegalMonetaryTotal
Pattern vrbl-invoice-sa-1p2
Severity fatal

Implementation

(cbc:LineExtensionAmount/@currencyID = $SADocumentCurrencyCode or not(cbc:LineExtensionAmount/@currencyID)) and (cbc:TaxExclusiveAmount/@currencyID = $SADocumentCurrencyCode or not(cbc:TaxExclusiveAmount/@currencyID)) and (cbc:TaxInclusiveAmount/@currencyID = $SADocumentCurrencyCode or not(cbc:TaxInclusiveAmount/@currencyID)) and (cbc:PayableAmount/@currencyID = $SADocumentCurrencyCode or not(cbc:PayableAmount/@currencyID)) and (cbc:AllowanceTotalAmount/@currencyID = $SADocumentCurrencyCode  or not(cbc:AllowanceTotalAmount/@currencyID)) and (cbc:PrepaidAmount/@currencyID = $SADocumentCurrencyCode  or not(cbc:PrepaidAmount/@currencyID))