Decimal places in the invoice line allowance base amount

Error BR-DEC-25 EN 16931

The allowed maximum number of decimals for the Invoice line allowance base amount (BT-137) is 2.

Mandatory rule: As long as it is violated, the invoice is invalid and will be rejected by validators.
What is wrong

The value in ram:BasisAmount has more than two decimal places.

What the rule means

The invoice line allowance base amount may have no more than two decimal places.

Affected fields BT-137
Please limit the decimal places in the invoice line allowance base amount

The invoice line allowance base amount has more than two decimal places. You can resolve this by adjusting the value in ram:BasisAmount to the permitted number of decimal places.

What to do
  1. Check the value of AbstractTradeAllowanceCharge.BasisAmount.
  2. Make sure the base amount has no more than two decimal places.
  3. Generate the invoice again and validate it.
What it looks like
✗ Triggers the message
<ram:SpecifiedTradeAllowanceCharge>
  <ram:ChargeIndicator>
    <udt:Indicator>false</udt:Indicator>
  </ram:ChargeIndicator>
  <ram:BasisAmount>1.234</ram:BasisAmount>
</ram:SpecifiedTradeAllowanceCharge>
✓ Correct
<ram:SpecifiedTradeAllowanceCharge>
  <ram:ChargeIndicator>
    <udt:Indicator>false</udt:Indicator>
  </ram:ChargeIndicator>
  <ram:BasisAmount>1.23</ram:BasisAmount>
</ram:SpecifiedTradeAllowanceCharge>
Check in FactoorSharp
  • AbstractTradeAllowanceCharge.BasisAmount (Line level allowance: BT-137)
Technical details

The check counts the characters after the decimal point in the allowance’s ram:BasisAmount and permits no more than two.

Where the rule applies

The rule applies to ram:BasisAmount for an allowance in ram:SpecifiedTradeAllowanceCharge on an invoice line.

Context (rule/@context)
//ram:SpecifiedLineTradeSettlement/ram:SpecifiedTradeAllowanceCharge/ram:ChargeIndicator[udt:Indicator = 'false']
Test expression (assert/@test)
string-length(substring-after(../ram:BasisAmount,'.'))<=2