I am using angular slickgrid to show my data. I monitoring the data continuously. If any changes happened in server side, that data need to update in application. So that modified data updated in slickgrid by this code this.angularGrid.gridService.updateDataGridItem(data);
. While updating data, the angular slickgrid fully rendered for multiple times. I want avoid angular slickgrid multiple times rendering.
Current behavior
While adding or updating a record, angular slickgrid renders multiple time
Expecting behavior
While adding or updating a record, angular slickgrid needs to update the particular row dataview only
Here i shared my gridoptions for your reference.
public gridOptions: GridOption = {
enablePagination: true,
autoEdit: false,
enableCellNavigation: true,
editable: true,
enableAutoResize: true,
enableSorting: true,
enableFiltering: true,
enableExcelExport: true,
enableExport: true,
i18n: this.translateService,
gridMenu: {
hideExportExcelCommand: true,
hideExportCsvCommand: true,
customItems: [{
command: "cspfm-excel-export",
titleKey: "EXPORT_TO_EXCEL",
iconCssClass: "fa fa-file-excel-o",
action: (event, callbackArgs) => {
this.excelExport(event, callbackArgs)
}
}, {
command: "cspfm-csv-export",
titleKey: "EXPORT_TO_CSV",
iconCssClass: "fa fa-download",
action: (event, callbackArgs) => {
this.excelExport(event, callbackArgs)
}
}],
},
enableAutoTooltip: true,
autoTooltipOptions: {
enableForCells: true,
enableForHeaderCells: true,
maxToolTipLength: 1000
},
headerMenu: {
hideColumnHideCommand: true
},
autoResize: {
containerId: this.gridContainerId,
calculateAvailableSizeBy: 'container'
},
exportOptions: {
exportWithFormatter: true
},
excelExportOptions: {
exportWithFormatter: true,
},
enableTranslate: true,
presets: {
sorters: [{ columnId: this.tableColumnInfo['pfm138993_institutename']['prop'], direction: 'ASC' }],
},
enableAsyncPostRender: true, // for the Angular PostRenderer, don't forget to enable it
asyncPostRenderDelay: 0, // also make sure to remove any delay to render it
params: {
angularUtilService: this.angularUtilService // provide the service to all at once (Editor, Filter, AsyncPostRender)
},
checkboxSelector: {
// you can toggle these 2 properties to show the "select all" checkbox in different location
hideInFilterHeaderRow: false,
},
rowSelectionOptions: {
// True (Single Selection), False (Multiple Selections)
selectActiveRow: false,
},
enableCheckboxSelector: true,
enableRowSelection: true
};
Software Version
Angular : 7.3.5
Angular-Slickgrid : 2.19.0
TypeScript : 3.1.6
Operating System : Windows 10
Node : 10.16.3
NPM : 6.9.0