Completed
Last Updated: 12 Dec 2024 14:43 by ADMIN
Release 2025 Q1 (Feb)
Alexa
Created on: 25 Oct 2024 21:14
Category: Kendo UI for jQuery
Type: Bug Report
1
Grid internal _data array out of sync with the tablerow elements

Hello,

My use case:

On grid dataBound, I am iterating over the table rows to perform some piece of custom logic on the row based off of the backing dataItem. Our production site is using version 2024.1.130, and everything is working great. Our next release we've updated to version 2024.2.514, and when we try adding a record, we get an error; when we try to access the dataItem of the last table-row - the dataItem is undefined. The grid.items() in my case is an array of size 21, and the internal _data array is size 20.

Repro conditions (as far as I can tell):

  • A Grid backed by a DataSource with server operations set to false
  • The DataSource should (?) have a filter configured
  • The size of the DataSource's data should (?) be larger than the pageSize

My workaround:

Simply perform a null check on the dataItem before doing the logic. We are calling DataSource.read in the DataSource.sync success callback anyway, so the grid will reload and the dataBound event will be handled afresh.

I've created the below dojo snippet to demonstrate a simplified version of my use case. I tested with 2024.1.130 and seems to work fine. I noticed the issue starting at version 2024.1.319.

https://dojo.telerik.com/INbSBrSg

 

A note: No, I don't actually use the internal _data property in my code, just for debugging purposes :)

Thanks!

-Alexa

1 comment
ADMIN
Neli
Posted on: 01 Nov 2024 10:11

Hello Alexa,

Thank you very much for your report. I am changing the status of the item to 'Unplanned'. Below you will find a link to the related issue in our GitHub repository:

- https://github.com/telerik/kendo-ui-core/issues/8032

As a small token of gratitude for reporting a bug, I have increased your Telerik points. 

Regards,
Neli
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.