Check documentation for the latest version of dhtmlxSuite FilterInterface Object DHTMLX Docs

FilterInterface Object

add

adds a new filtering rule to collection

$coll->add("name","value");  _$name LIKE $value
_or
$coll->add("name","value","comp_oper"); //name < value

Parameters:

  • name - name of the field.
  • value - comparison value (filtering criteria).
  • comp_oper - comparison operator: '>' or '<'.

See also:

clear

clears collection (deletes all specified filtering rules)

$coll->clear();

Parameters:

  • none.

index

checks if there are some rules in collection for the specified field and returns a related hash

$index = $coll->index("name");

Parameters:

  • name - name of the field

Returns:

  • true - if collection contains rule(s) for the specified field.
  • false - if collection doesn't contain any rules for the field.

See also:

rules

an array of all specified sorting rules

$name = $coll->rules[0]["name"]
$coll->rules[0]["value"]="cde";

Properties:

  • name - name of related field.
  • value - comparison value (filtering criteria).
  • operation - comparison operator. If empty, the default LIKE instruction is used.

See also:

Back to top