-
Main
- Dashboard No active orders
- Layouts
- Themes
- Starter kit
- Changelog2.0
- RTL version
-
Forms
- Form components
- JSON forms
- Text editors
- Pickers
- Form layouts
-
Components
- Basic components
- Content styling
- Extra components
- Color system
- Animations
- Icons
-
Layout
- Page layouts
- Sidebars
- Navbars
- Vertical navigation
- Horizontal navigation
- Menu levels
-
Data visualization
- Echarts library
- D3 library
- Dimple library
- C3 library
- Google charts
- Maps integration
-
Extensions
- Extensions
- JQuery UI
- File uploaders
- Event calendars
- Internationalization
-
Tables
- Basic tables
- Data tables
- Data tables extensions
- Handsontable
- Responsive tables
-
Page kits
- General pages
- Service pages
- User pages
- Application pages
- Widgets
Search plugin provides an easy interface to perform data search across Handsontable. First thing you should do, is enabling the plugin by setting the searchoption to true. When enabled, searchPluginexposes a new method query(queryStr), where queryStris a string to find within the table. By default, the search is case insensitive.
By default searchPluginadds htSearchResultclass to every cell which isSearchResultproperty is true. You can change this class using searchResultClassoption. If you wish to change the result class globally (for all Handsontable instances on the page), you can use Handsontable.Search.global.setDefaultSearchResultClass(className)method.
The queryMethodis responsible for determining whether a queryStrmatches the value stored in a cell. It takes 2 arguments: queryStrand cellData. The first is a string passed to query()method. The second is a value returned by getDataAtCell(). The queryMethodfunction should return true if there is a match.
After calling queryMethod, searchPlugincalls callback(instance, rowIndex, colIndex, cellData, testResult)for every cell. The default callback is responsible for setting the isSearchResultproperty, so if you want to preserve this functionality, be sure to invoke Handsontable.Search.DEFAULT_CALLBACKinside your custom callback.
0results found

