Skip to content

getFilter

returns the filter object that is used to filter the values of the specified column

function getFilter(
// the id of a column
columnID: id
): object|HTMLElement

object,HTMLElement the Webix view object or the HTML element of the filter

columns:[
{ id:"title", header:["Film title", {content:"textFilter"}] },
{ id:"year", header:["Released", {content:"selectFilter"}] }
]
// ...
// gets to the filter object of each column and retrieves its current value
var title = this.getFilter("title").value;
var year = this.getFilter("year").value;

also check the next samples:

Depending on the filter type, the method returns either the HTML element or the Webix view object of the filter.

An HTML element is returned for the filters based on HTML5 inputs:

  • textFilter
  • numberFilter
  • selectFilter
  • dateFilter
  • server equivalents of the above

A Webix view object is returned for the filters based on Webix inputs:

  • richSelectFilter
  • multiSelectFilter
  • multiComboFilter
  • datepickerFilter
  • dateRangeFilter
  • server equivalents of the above

Articles

API