Sum of charges on document level (BT-108) = Σ Document level charge amount (BT-99).
ChargeTotalAmount does not equal the sum of the document-level charge amounts. Amounts from SpecifiedLogisticsServiceCharge are also included in the check. If there are no charges, ChargeTotalAmount may be omitted.
The total amount of charges at document level must reflect the individual charge amounts included in it. This ensures that BT-108 matches the amounts from which it is calculated.
The total charge amount does not match the individual charge amounts. You can adjust the invoice so that the amounts match.
- Compare
ChargeTotalAmountwith the document-level charge amounts. - Also include the amounts in
SpecifiedLogisticsServiceCharge. - Check the
ChargeTotalAmountproperty and the amounts inActualAmount. - Generate the invoice again and validate it again.
<ram:SpecifiedTradeSettlementHeaderMonetarySummation> <ram:ChargeTotalAmount>16.00</ram:ChargeTotalAmount> </ram:SpecifiedTradeSettlementHeaderMonetarySummation> <ram:SpecifiedTradeAllowanceCharge> <ram:ChargeIndicator> <udt:Indicator>true</udt:Indicator> </ram:ChargeIndicator> <ram:ActualAmount>10.00</ram:ActualAmount> </ram:SpecifiedTradeAllowanceCharge> <ram:SpecifiedLogisticsServiceCharge> <ram:AppliedAmount>5.00</ram:AppliedAmount> </ram:SpecifiedLogisticsServiceCharge>
<ram:SpecifiedTradeSettlementHeaderMonetarySummation> <ram:ChargeTotalAmount>15.00</ram:ChargeTotalAmount> </ram:SpecifiedTradeSettlementHeaderMonetarySummation> <ram:SpecifiedTradeAllowanceCharge> <ram:ChargeIndicator> <udt:Indicator>true</udt:Indicator> </ram:ChargeIndicator> <ram:ActualAmount>10.00</ram:ActualAmount> </ram:SpecifiedTradeAllowanceCharge> <ram:SpecifiedLogisticsServiceCharge> <ram:AppliedAmount>5.00</ram:AppliedAmount> </ram:SpecifiedLogisticsServiceCharge>
FacturXInvoice.ChargeTotalAmount(BT-108)AbstractTradeAllowanceCharge.ActualAmount(Document level charge: BT-99)
Technical details
The rule compares ChargeTotalAmount, rounded to two decimal places, with the sum of ActualAmount values for entries whose ChargeIndicator is true and AppliedAmount values from SpecifiedLogisticsServiceCharge.
The rule applies to the total amounts in SpecifiedTradeSettlementHeaderMonetarySummation and to document-level charges in ApplicableHeaderTradeSettlement.
rule/@context)assert/@test)