diff --git a/aurelia-slickgrid/src/aurelia-slickgrid/models/backendService.interface.ts b/aurelia-slickgrid/src/aurelia-slickgrid/models/backendService.interface.ts index 79502c271..3fc4c0db2 100644 --- a/aurelia-slickgrid/src/aurelia-slickgrid/models/backendService.interface.ts +++ b/aurelia-slickgrid/src/aurelia-slickgrid/models/backendService.interface.ts @@ -56,11 +56,11 @@ export interface BackendService { // ----------------- /** Execute when any of the filters changed */ - onFilterChanged: (event: Event, args: FilterChangedArgs) => Promise; + processOnFilterChanged: (event: Event, args: FilterChangedArgs) => Promise; /** Execute when the pagination changed */ - onPaginationChanged: (event: Event | undefined, args: PaginationChangedArgs) => string; + processOnPaginationChanged: (event: Event | undefined, args: PaginationChangedArgs) => string; /** Execute when any of the sorters changed */ - onSortChanged: (event: Event | null, args: SortChangedArgs) => string; + processOnSortChanged: (event: Event | null, args: SortChangedArgs) => string; } diff --git a/aurelia-slickgrid/src/aurelia-slickgrid/services/filter.service.ts b/aurelia-slickgrid/src/aurelia-slickgrid/services/filter.service.ts index 82312c637..a9e31b5f6 100644 --- a/aurelia-slickgrid/src/aurelia-slickgrid/services/filter.service.ts +++ b/aurelia-slickgrid/src/aurelia-slickgrid/services/filter.service.ts @@ -87,7 +87,7 @@ export class FilterService { } // call the service to get a query back - const query = await backendApi.service.onFilterChanged(event, args); + const query = await backendApi.service.processOnFilterChanged(event, args); // emit an onFilterChanged event this.emitFilterChanged('remote'); diff --git a/aurelia-slickgrid/src/aurelia-slickgrid/services/graphql.service.ts b/aurelia-slickgrid/src/aurelia-slickgrid/services/graphql.service.ts index bb20c4275..d282f5955 100644 --- a/aurelia-slickgrid/src/aurelia-slickgrid/services/graphql.service.ts +++ b/aurelia-slickgrid/src/aurelia-slickgrid/services/graphql.service.ts @@ -250,7 +250,7 @@ export class GraphqlService implements BackendService { /* * FILTERING */ - onFilterChanged(event: Event, args: FilterChangedArgs): Promise { + processOnFilterChanged(event: Event, args: FilterChangedArgs): Promise { const gridOptions: GridOption = this._gridOptions || args.grid.getOptions(); const backendApi = gridOptions.backendServiceApi; @@ -310,7 +310,7 @@ export class GraphqlService implements BackendService { * } * } */ - onPaginationChanged(event: Event, args: PaginationChangedArgs) { + processOnPaginationChanged(event: Event, args: PaginationChangedArgs) { const pageSize = +(args.pageSize || ((this.pagination) ? this.pagination.pageSize : DEFAULT_PAGE_SIZE)); this.updatePagination(args.newPage, pageSize); @@ -323,7 +323,7 @@ export class GraphqlService implements BackendService { * we will use sorting as per a Facebook suggestion on a Github issue (with some small changes) * https://github.com/graphql/graphql-relay-js/issues/20#issuecomment-220494222 */ - onSortChanged(event: Event, args: SortChangedArgs) { + processOnSortChanged(event: Event, args: SortChangedArgs) { const sortColumns = (args.multiColumnSort) ? args.sortCols : new Array({ sortCol: args.sortCol, sortAsc: args.sortAsc }); // loop through all columns to inspect sorters & set the query diff --git a/aurelia-slickgrid/src/aurelia-slickgrid/services/grid-odata.service.ts b/aurelia-slickgrid/src/aurelia-slickgrid/services/grid-odata.service.ts index 0abeb8876..8c2c8a41d 100644 --- a/aurelia-slickgrid/src/aurelia-slickgrid/services/grid-odata.service.ts +++ b/aurelia-slickgrid/src/aurelia-slickgrid/services/grid-odata.service.ts @@ -126,7 +126,7 @@ export class GridOdataService implements BackendService { /* * FILTERING */ - onFilterChanged(event: Event, args: FilterChangedArgs): Promise { + processOnFilterChanged(event: Event, args: FilterChangedArgs): Promise { const serviceOptions: GridOption = args.grid.getOptions(); const backendApi = serviceOptions.backendServiceApi; @@ -159,7 +159,7 @@ export class GridOdataService implements BackendService { /* * PAGINATION */ - onPaginationChanged(event: Event, args: PaginationChangedArgs) { + processOnPaginationChanged(event: Event, args: PaginationChangedArgs) { const pageSize = +(args.pageSize || DEFAULT_PAGE_SIZE); this.updatePagination(args.newPage, pageSize); @@ -170,7 +170,7 @@ export class GridOdataService implements BackendService { /* * SORTING */ - onSortChanged(event: Event, args: SortChangedArgs) { + processOnSortChanged(event: Event, args: SortChangedArgs) { const sortColumns = (args.multiColumnSort) ? args.sortCols : new Array({ sortCol: args.sortCol, sortAsc: args.sortAsc }); // loop through all columns to inspect sorters & set the query diff --git a/aurelia-slickgrid/src/aurelia-slickgrid/services/sort.service.ts b/aurelia-slickgrid/src/aurelia-slickgrid/services/sort.service.ts index c0e6771df..6ba215a77 100644 --- a/aurelia-slickgrid/src/aurelia-slickgrid/services/sort.service.ts +++ b/aurelia-slickgrid/src/aurelia-slickgrid/services/sort.service.ts @@ -67,7 +67,7 @@ export class SortService { if (backendApi.preProcess) { backendApi.preProcess(); } - const query = backendApi.service.onSortChanged(event, args); + const query = backendApi.service.processOnSortChanged(event, args); this.emitSortChanged('remote'); // await for the Promise to resolve the data diff --git a/aurelia-slickgrid/src/aurelia-slickgrid/slick-pagination.ts b/aurelia-slickgrid/src/aurelia-slickgrid/slick-pagination.ts index 365a0488c..bcdb361a2 100644 --- a/aurelia-slickgrid/src/aurelia-slickgrid/slick-pagination.ts +++ b/aurelia-slickgrid/src/aurelia-slickgrid/slick-pagination.ts @@ -160,7 +160,7 @@ export class SlickPaginationCustomElement { backendApi.preProcess(); } - const query = backendApi.service.onPaginationChanged(event, { newPage: pageNumber, pageSize: itemsPerPage }); + const query = backendApi.service.processOnPaginationChanged(event, { newPage: pageNumber, pageSize: itemsPerPage }); // await for the Promise to resolve the data const processResult = await backendApi.process(query);