XRechnung 2.6.0 · UBL

BR-CO-12

XRechnung 2.6.0 · UBL

fatalbusiness

Original rule text

[BR-CO-12]-Sum of charges on document level (BT-108) = Σ Document level charge amount (BT-99).

Stored validation assertion
xs:decimal(cbc:ChargeTotalAmount) = (round(sum(../cac:AllowanceCharge[cbc:ChargeIndicator=true()]/xs:decimal(cbc:Amount)) * 10 * 10) div 100) or (not(cbc:ChargeTotalAmount) and not(../cac:AllowanceCharge[cbc:ChargeIndicator=true()]))