Posted 29 June 2023, 6:08 pm EST
Hi Nilesh,
It seems you are handling the ‘initialized’ event of the FlexGridFilter and adding an event listener to the ‘filterChanging’ event inside the ‘initFilter’ method. Now, either you can add another event listener to the ‘filterChanging’ event by updating the FlexGridFilter line in your ‘component.html’ file like this -
<wj-flex-grid-filter (initialized)="initFilter(filter)" (filterChanging)="filterChanging(filter, $event)" #filter></wj-flex-grid-filter>
and inserting the following method in your ‘component.ts’ file -
filterChanging(filter: wjGridFilter.FlexGridFilter, e: any) {
let valueFilterEditor: any = wjCore.Control.getControl(filter.activeEditor.hostElement.querySelector('.wj-valuefilter-editor'));
if (valueFilterEditor) {
valueFilterEditor.canApply = true;
valueFilterEditor.canApplyChanged.addHandler((s: wjGridFilter.ValueFilterEditor, e: any) => {
s.canApply = true;
})
}
}
OR
You can also insert the same code in the ‘filterChanging’ event that you’ve handled in the initFilter method. You can refer to the following sample for the same which is updated according to your implementation - https://jscodemine.grapecity.com/share/wF9ETIL6m0OxmZO0sDpetg
In case, you still face any issues, please let us know.
Regards