0

This has no effect on backend call request. Any idea why and how to make a new odata request with added filter query.

public setFilter(filter: string) {
    console.log("set filter ", filter);
    this.filterValue = filter;
    const odataService = this.gridOptions.backendServiceApi.service;
    console.log("filterValue ", this.filterValue);
    odataService.updateOptions({ filter: this.filterValue } as OdataOption);
    console.log("odataService update ", odataService);
    odataService.processOnFilterChanged

    odataService.clearFilters();
    this.aureliaGridObj.filterService.clearFilters();
    return true;
}
sb32134
  • 426
  • 8
  • 19
  • 1
    I wrote that service long time ago and I didn't use it since then but I don't think you should touch the `updateOptions`, I think this is for internal use only and you might be breaking all grid filters if you do that. You're probably better of modifying the query returned by the `process: (query)...` callback, that is what sends the query string to the backend. You should also refer to the [OData Wiki](https://github.com/ghiscoding/aurelia-slickgrid/wiki/OData) – ghiscoding Feb 19 '21 at 14:40
  • thanks, that seems to work by modifying the query string. – sb32134 Feb 19 '21 at 16:38

0 Answers0