- FilterWidget can represents the retrieved data with tablesorter or pivotUI

- Added new constants to FiltersLib
- Added new parameter pivotui to FHC-Header to load JS and CSS for pivotUI
- Renamed constat WIDGET_URL_TABLE_DATASET to WIDGET_URL_DATASET_TABLESORTER in FilterWidget
- Added new constat WIDGET_URL_DATASET_PIVOTUI to FilterWidget
- Added new private properties _datasetRepresentation and _datasetRepresentationOptions to FilterWidget
- Renamed FilterWidget->loadViewTableDataset to loadViewDataset
- FilterWidget->loadViewDataset loads tablesorter or pivotUI view depending on the value of property _datasetRepresentation
- FilterWidget accepts two new parameter: datasetRepresentation and datasetRepOptions
- datasetRepresentation is required
- FilterWidget stores in session the _datasetRepresentation and _datasetRepresentationOptions properties
- Adapted view views/widgets/filter/filter to use loadViewDataset
- All views using FilterWidget have been adapted to use the required parameter datasetRepresentation
- Added new constats DATASET_REP_TABLESORTER and DATASET_REP_PIVOTUI to public/js/FilterWidget.js
- Added new private property _datasetRepresentation to FHC_FilterWidget in public/js/FilterWidget.js
- Based on property _datasetRepresentation FilterWidget.js will represent the FilterWidget data with tablesorter or pivotUI
- Added new private method _renderDataset to FHC_FilterWidget in public/js/FilterWidget.js
- Renamed method _renderTableDataset to _renderDatasetTablesorter in FHC_FilterWidget in public/js/FilterWidget.js
- Added new method _renderDatasetPivotUI to FHC_FilterWidget in public/js/FilterWidget.js
- Added bew method _setDatasetRepresentation to FHC_FilterWidget in public/js/FilterWidget.js
This commit is contained in:
Paolo
2019-01-11 15:14:53 +01:00
parent a090468126
commit fa9976ec66
11 changed files with 229 additions and 21 deletions
+10
View File
@@ -20,6 +20,8 @@ class FiltersLib
const SESSION_DATASET = 'dataset';
const SESSION_ROW_NUMBER = 'rowNumber';
const SESSION_RELOAD_DATASET = 'reloadDataset';
const SESSION_DATASET_REPRESENTATION = 'datasetRepresentation';
const SESSION_DATASET_REP_OPTIONS = 'datasetRepresentationOptions';
// Alias for the dynamic table used to retrive the dataset
const DATASET_TABLE_ALIAS = 'datasetFilterTable';
@@ -55,6 +57,14 @@ class FiltersLib
const CUSTOM_MENU = 'customMenu'; // ...to specify if the menu for this filter is custom (true) or not (false)
// ...to specify how to represent the dataset (ex: tablesorter, pivotUI, ...)
const DATASET_REPRESENTATION = 'datasetRepresentation';
const DATASET_REP_OPTIONS = 'datasetRepOptions';
// Different dataset representations
const DATASET_REP_TABLESORTER = 'tablesorter';
const DATASET_REP_PIVOTUI = 'pivotUI';
// Filter operations values
const OP_EQUAL = 'equal';
const OP_NOT_EQUAL = 'nequal';