Completed
Last Updated: 09 May 2022 15:57 by ADMIN
Release 2022.R2
SturmA
Created on: 15 Dec 2021 14:44
Category: Grid
Type: Bug Report
1
Grid Group Paging and Filter Checkboxes aren't compatible

Bug report

When the Grid's Group Paging is enabled and its content is grouped, the Multicheckbox Filter doesn't filter the group data correctly.

Reproduction of the problem

  1. Run this REPL Example.
  2. Group by a column for example „City”
  3. Filter the Country column for example „USA”
  4. Check the result for a specific City group

Current behavior

The group shows rows that shouldn't be included when the column is filtered properly

Expected/desired behavior

The group should only show the filtered rows

TicketID:

1546090

Environment

  • Kendo UI version: 2021.3.1207
  • Browser: [all]
1 comment
ADMIN
Stoyan
Posted on: 15 Dec 2021 14:59

Hi SturmA,

Thank you for your report.

Until this issue is fixed you can workaround it by modifying  the DataSource's internal _composeItemsFilter method:

kendo.data.DataSource.fn._composeItemsFilter = function (group, parents) {
                var filter = this.filter() || {
                    logic: 'and',
                    filters: []
                };
                filter.logic = 'and';
                filter = $.extend(true, {}, filter);
                filter.filters.push({
                    field: group.field,
                    operator: 'eq',
                    value: group.value
                });
                if (parents) {
                    for (var i = 0; i < parents.length; i++) {
                        filter.filters.push({
                            field: parents[i].field,
                            operator: 'eq',
                            value: parents[i].value
                        });
                    }
                }
                return filter;
            }

Please review a runnable sample of the approach in the following REPL.

Regards,
Stoyan
Progress Telerik

Love the Telerik and Kendo UI products and believe more people should try them? Invite a fellow developer to become a Progress customer and each of you can get a $50 Amazon gift voucher.