Kendo-angular: Grid filterChange event doesn't provide which filter was cleared

Created on 10 Jul 2018  路  2Comments  路  Source: telerik/kendo-angular

I'm submitting a...

  • Bug report

Current behavior


The filterChange event doesn't provide information about the filter when a filter is cleared.

Expected behavior


The event should provide which filter was just cleared.

Minimal reproduction of the problem with instructions


Check console.log output on line 52.. Entering a value in the "Product Name" filter produces information about the value and filter used but clearing it doesn't provide information that "ProductName" filter was cleared.
https://plnkr.co/edit/joBcwIiTy0XrCpmr4Tqa?p=preview

image

Environment

Browser:

  • Chrome (desktop) version 67

System:

  • Platform: Windows

Question grid

All 2 comments

Hi @Pradhyo, the descriptor provided in filter change event represents the current state of the Grid component. It is intentional that it does not give explicitly information about what has been changed between state changes. If you need such information you should manually compare the current and previous state of the descriptor.

Ah got it, thanks for getting back.
In my actual code, I forgot this line.

<kendo-grid
        ....
        [filter]="filter"
        ....
>

Without this, the event only had information for the filter that just changed but not all of them. This is why I was using this information to track all the filters myself which I don't need to do anymore.

Was this page helpful?
0 / 5 - 0 ratings