Class BTM.Table.Dynamic
Dynamic Table to allow sorting, filtering, etc
Defined in: table.js.
| Constructor Attributes | Constructor Name and Description |
|---|---|
|
BTM.Table.Dynamic(element, options)
|
| Method Attributes | Method Name and Description |
|---|---|
|
display()
Refreshes the HTML table with the relevant data, based on sorting, filtering & pageing (not yet implemented)
|
|
|
filter()
Filter the data shown in the Table
|
|
|
filterTimeout(event)
Helper for the BTM.Table.Dynamic#filter method, to allow as-you-type filtering.
|
|
|
sort(event, column, keepDirection)
Sort the table, on the specified column
|
Class Detail
BTM.Table.Dynamic(element, options)
- Parameters:
- {HTMLElement|String} element
- element ID or element reference to existing HTML table
- {Object} options Optional
- options for the Dynamic Table
- {Boolean} options.rememberSorting Optional, Default: true
- flag to remember the sort-order of the Dynamic Table across page loads (not yet implemented)
- {Array} options.columnTypes Optional
- an Array to force columns to be handled as a specific type, overriding the automatic detection. Valid types are currently "currency", "numeric" & "checkbox"
- {Array} options.filterTypes Optional
- an Array to force columns to have the specified filter type, overriding the automatic detection. Valid types are currently "select"
Method Detail
display()
Refreshes the HTML table with the relevant data, based on sorting, filtering & pageing (not yet implemented)
filter()
Filter the data shown in the Table
filterTimeout(event)
Helper for the BTM.Table.Dynamic#filter method, to allow as-you-type filtering.
- Parameters:
- event
sort(event, column, keepDirection)
Sort the table, on the specified column
- Parameters:
- {Event} event
- the event that triggered the sort, or false (if called programatically)
- {Number} column
- the column number to sort on (starting at 0)
- {Boolean} keepDirection Optional
- override the order detection and keep the current sort direction