All docs
V19.2
24.1
The page you are viewing does not exist in version 24.1.
23.2
The page you are viewing does not exist in version 23.2.
23.1
The page you are viewing does not exist in version 23.1.
22.2
The page you are viewing does not exist in version 22.2.
22.1
The page you are viewing does not exist in version 22.1.
21.2
The page you are viewing does not exist in version 21.2.
21.1
The page you are viewing does not exist in version 21.1.
20.2
The page you are viewing does not exist in version 20.2.
20.1
The page you are viewing does not exist in version 20.1.
19.2
19.1
18.2
18.1
17.2
The page you are viewing does not exist in version 17.2.
Vue
A newer version of this page is available. Switch to the current version.

jQuery FilterBuilder - customOperations

Configures custom filter operations.

Default Value: []

calculateFilterExpression

Specifies a function that returns a filter expression for this custom operation.

Type:

Function

Function parameters:
filterValue: any

A FilterBuilder field's value.

The field's configuration.

Return Value:

Filter Expression

A filter expression with filter operations supported by the DataSource.
These operations are: "!", "=", "<>", ">", ">=", "<", "<=", "startswith", "endswith", "contains", "notcontains", "and", "or".

NOTE
The this keyword refers to the custom operation's configuration.

View Demo

See Also

caption

Specifies the operation's caption.

Type:

String

Default Value: undefined

customizeText

Customizes the field value's text representation.

Type:

Function

Function parameters:
fieldInfo:

Object

Information about a FilterBuilder field.

Object structure:
Name Type Description
field

FilterBuilder Field

The field's configuration.

value

String

|

Number

|

Date

The field's unformatted value (specified using the editor).

valueText

String

The value with the format applied.

Return Value:

String

The text to be displayed.

NOTE
The this keyword refers to the custom operation's configuration.

dataTypes

Specifies for which data types the operation is available by default.

Type:

Array<String>

Default Value: undefined
Accepted Values: 'string' | 'number' | 'date' | 'boolean' | 'object' | 'datetime'

Define this option to make the custom operation available for all fields of specific data types. You can also make the operation available for an individual field by including the operation's name in the field's filterOperations array.

editorComponent

An alias for the editorTemplate property specified in React. Accepts a custom component. Refer to Using a Custom Component for more information.

editorRender

An alias for the editorTemplate property specified in React. Accepts a rendering function. Refer to Using a Rendering Function for more information.

editorTemplate

Specifies a custom template for the widget used to edit the field value.

Type:

template

Template Data:
Name Type Description
field

FilterBuilder Field

The field's configuration.

setValue

Function

A method you should call to change the field value after the editor value changes.

value

String

|

Number

|

Date

The editor's value.

hasValue

Specifies whether the operation can have a value. If it can, the editor is displayed.

Type:

Boolean

Default Value: true

icon

Specifies the icon that should represent the filter operation.

Type:

String

Default Value: undefined

This option accepts one of the following:

name

Specifies the operation's identifier.

Type:

String

Default Value: undefined