Finds the search and returns its object or index in searches array.
getSearch([field], [returnIndex])
field |
string, optional field name of the search |
returnIndex |
boolean, optional indicates if return a search or its index in searches array |
Returns object, integer or null.
Description
The search is identified by the
.field property, which is a required property for each search object. The
method loops through the
.searches array to find the search object.
If called w/o parameters, it will return array of search names.
If you have grid defined in the following way:
You can get the search: