Configuration fields
Validation rules
Core calculation
- Start from the gross bill amount (after quantity discounts, the pricing model, and commitments), then subtract any fixed discount that runs ahead of it in the stack, per the default order.
- Apply the percentage: discount = value% × amount.
- Subtract: invoice_amount = amount − discount, floored at $0.
Order of operations (full calculation stack)
Natural ordering when stacking discount types
Multiple percent discounts compound rather than add: 20% + 10% = 1 − (0.8 × 0.9) = 28%, not 30%. The order between multiple percent discounts never changes the result, since compounding is commutative.