1.0.13 • Published 7 years ago

tm.components.datagrid v1.0.13

Weekly downloads
5
License
-
Repository
-
Last release
7 years ago

tm.components.dialogue

Versions:

1.0.0: Initial version 1.0.1 Updated readme 1.0.2 Added dropdownpager 1.0.3 Update to row CSS 1.0.4 Update to action links CSS 1.0.5 Added executeOnReadyFunctions 1.0.6 Things went missing? 1.0.7 Made some things nullable and added defaults 1.0.8 Update to the utility to allow bodies to be used with databinding using the databinding attribute on a row Added hidden support 1.0.9 Fixed executeOnReadyFunctions 1.0.11 Can now set selection column width. Defaults to 50px. 1.0.12 small css fix 1.0.13 Split settings into modules

Includes:

Dependencies:

  • tm.devExpress
  • jQuery 1.11+
  • tm.componentBase

Usage:

var columnChooserSettings = { showColumnChooser: true, mode: "select", width: "300px" };

var selectionSettings = { showSelection: true, mode: "multiple", selectAllMode: "allPages" }

var groupingSettings = { enableGrouping: true, expandMode: TM.Components.DataGrid.Modules.Grouping.ExpandModeType.RowClick, autoExpandAll: true, allowCollapsing: true }

var columnChooserModule = new TM.Components.DataGrid.Modules.ColumnChooser.DataGridColumnChooser(columnChooserSettings); var selectionModule = new TM.Components.DataGrid.Modules.Selection.DataGridSelection(selectionSettings); var groupingModule = new TM.Components.DataGrid.Modules.Grouping.DataGridGrouping(groupingSettings);

var builder = new DataGridBuilder(); var grid = builder.createDefaultGrid({ headers: headers, gridElement: $(".datagrid"), dataSource: objectList, modules: columnChooserModule, selectionModule, groupingModule });

var module = grid.getModule(TM.Components.DataGrid.Modules.Selection.DataGridSelection); var selectedRows = module.getSelectedRows();