Each Invoice line allowance (BG-27) shall have an Invoice line allowance reason (BT-139) or an Invoice line allowance reason code (BT-140).
The invoice line allowance contains neither ram:Reason nor ram:ReasonCode. Each such allowance must have a reason or a reason code.
A reason or reason code explains the allowance on the invoice line.
A reason is missing for an allowance on the invoice line. You can provide a reason as text or as a code.
- Add either
ram:Reasonorram:ReasonCodeunderram:SpecifiedTradeAllowanceCharge. - Set the text through
AbstractTradeAllowanceCharge.Reasonor the code throughTradeAllowance.ReasonCode. - Generate the invoice again and validate it once more.
<ram:SpecifiedTradeAllowanceCharge> <ram:ChargeIndicator> <udt:Indicator>false</udt:Indicator> </ram:ChargeIndicator> </ram:SpecifiedTradeAllowanceCharge>
<ram:SpecifiedTradeAllowanceCharge> <ram:ChargeIndicator> <udt:Indicator>false</udt:Indicator> </ram:ChargeIndicator> <ram:Reason>Motif</ram:Reason> </ram:SpecifiedTradeAllowanceCharge>
AllowanceReasonCodes(Line level allowance: BT-140)TradeAllowance.ReasonCode(Line level allowance: BT-140)AbstractTradeAllowanceCharge.Reason(Line level allowance: BT-139)TradeLineItem.SpecifiedTradeAllowanceCharges(BG-27)AbstractTradeAllowanceCharge(Line level allowance: BG-27)
Technical details
For the allowance identified by udt:Indicator with false, the test checks whether the parent ram:SpecifiedTradeAllowanceCharge contains ram:Reason or ram:ReasonCode.
The rule applies to an invoice line allowance identified by ram:ChargeIndicator with the value false.
rule/@context)assert/@test)