CustDirectDebitMandate::validateMandateOfInvoice Method
Validates the mandate used on an invoice.
Syntax
client server public static boolean validateMandateOfInvoice(
CustTrans _invoiceCustTrans,
boolean _shouldValidateBankAccount,
boolean _throwErrors,
[boolean _validateOnetimeMandateUsed])
Run On
Called
Parameters
- _invoiceCustTrans
Type: CustTrans Table
The CustTrans table record that represents the invoice.
- _shouldValidateBankAccount
Type: boolean
true if the bank account should be validated against the mandate.
- _throwErrors
Type: boolean
Determines if errors should be thrown for an invalid mandate.
- _validateOnetimeMandateUsed
Type: boolean
Return Value
Type: boolean
true if the mandate is valid; otherwise, false
Exceptions
Exception | Condition |
---|---|
Error | A valid mandate must be selected -or- The mandate must be complete -or- The mandate must not be cancelled -or- The mandate must not be expired -or- The bank account of the transaction must match the mandate -or- The transaction date plus pre-notification days must be less than or equal to the due date |