AddFilter(position, reference, type, label, displayType, defaultValue, helpText, source, maxLength)
Adds a filter on the Invoice Payment Processing page. The filter refines the search of invoices to be processed.
Parameters
-
isDefaultFilter{Booleantrue|false} [required] – If value istrue, the filter is added to the existing Search Filters group on the Invoice Payment Processing page. If value isfalse, a new group of filters, named Custom Transaction Filters, is added to the Invoice Payment Processing page. -
reference{string} [required] – The internal ID name of the field you want to add as a filter. Note that you can only add fields from the transaction record. If you want to source a newly created transaction body field or transaction column field, thereferenceargument must be the id of the newly created field. -
type{string} [required] – The field type of the filter. Valid arguments are listed below:-
text -
date -
checkbox -
select -
multiselect -
integer -
currency -
longtext
-
-
label{string} [required] – The label of the filter displayed on the Invoice Payment Processing page. -
displayType{string} [optional] – The display type of the filter on the Invoice Payment Processing page. Accepted values are listed below.-
inline -
normal -
hidden -
disabled
-
-
defaultValue{string} [optional] – The default value of the filter that is displayed automatically when the Invoice Payment Processing page loads. -
helpText{string} [optional] – The text displayed when the filter label is clicked. ThehelpTextvalue describes the data searched for when the filter is used. -
source{string} [optional] – Specifies the source where the filter gets its autopopulated values. An example value is the internal id of a list or record. Note thatsourcemust've a value if thetypeargument isselectormultiselect, for the values of the filter to be displayed. -
maxLength{string} [optional] – A whole number that defines the allowed length of the value entered on the filter.
Throws
-
EP_API_MISSING_FIELDS– Thrown when a required argument is missing. Logs “Please enter required filter parameters: position, type, name, reference.” -
EP_API_INVALID_POSITION_VALUE– Thrown when position value is not Boolean. -
EP_API_INVALID_TYPE_VALUE– Thrown when adding invalid type filter. Refer to the valid type filter values. -
EP_API_INVALID_DISPLAYTYPE_VALUE– Thrown when adding invalid displayType filter. Refer to the valid displayType filter values. -
EP_API_INVALID_DEFAULTVALUE_VALUE– Thrown when adding invalid defaultValue filter. Refer to the valid defaultValue filter values. -
EP_API_INVALID_MAXLENGTH_VALUE– Thrown when adding invalid maxLength filter. Refer to the valid maxLength filter values.
Example
epPaymentSelectionForm.AddFilter(true,'custcol_companyname', 'select', 'Custom Subsidiary', '', '', 'Custom Subsidiary', 'subsidiary', '');