function

getPaymentTotal

Calculate the display total with the same finite arithmetic model as Go.

Arguments

ArgumentTypeDescription
basePricenumberThe basePrice value.
conditionsreadonly PriceCondition[]The conditions value.
valuesReadonly<Record<string, FormValue>>The values value.

Returns

The declared result.

number

How it works

The trusted Go callback recalculates the authoritative total before commit.

Full signature

function getPaymentTotal( basePrice: number, conditions: readonly PriceCondition[], values: FormValues, ): number

Source packages/plugin-form-builder/src/lib/index.ts:4

Related types