diff --git a/aurelia-slickgrid/src/aurelia-slickgrid/services/controlAndPlugin.service.ts b/aurelia-slickgrid/src/aurelia-slickgrid/services/controlAndPlugin.service.ts index 21bdf303d..e3e9850d2 100644 --- a/aurelia-slickgrid/src/aurelia-slickgrid/services/controlAndPlugin.service.ts +++ b/aurelia-slickgrid/src/aurelia-slickgrid/services/controlAndPlugin.service.ts @@ -368,7 +368,7 @@ export class ControlAndPluginService { grid.setTopPanelVisibility(!grid.getOptions().showTopPanel); break; case 'refresh-dataset': - this.refreshBackendDataset(options); + this.refreshBackendDataset(); break; default: alert('Command: ' + args.command); @@ -411,13 +411,10 @@ export class ControlAndPluginService { }; } - /** - * Call a refresh dataset with a BackendServiceApi - * @param gridOptions - */ - refreshBackendDataset(gridOptions: GridOption) { + /** Call a refresh dataset with a BackendServiceApi */ + refreshBackendDataset() { let query; - const backendApi = gridOptions.backendServiceApi || gridOptions.onBackendEventApi; + const backendApi = this._gridOptions.backendServiceApi || this._gridOptions.onBackendEventApi; if (!backendApi || !backendApi.service || !backendApi.process) { throw new Error(`BackendServiceApi requires at least a "process" function and a "service" defined`); }