This is a migrated thread and some comments may be shown as answers.

The Refresh of Kendo Grid (with endless scrolling option) is not working properly

8 Answers 823 Views
Grid
This is a migrated thread and some comments may be shown as answers.
El Mehdi
Top achievements
Rank 1
El Mehdi asked on 02 Jul 2018, 03:12 PM

Hey,

I am working with Kendo Grid with endless Scroll option set to true. I know that we are not suppose to have paging option (Refresh) with the endless or virtual scrolling set to true, that's why I am looking for a workaround that allows us at least to reset the Grid from the start (before scrolling).

here is an example: https://dojo.telerik.com/OZUTIJEz    (Try to scroll and then hit the refresh icon)

There is always replicated/wrong data with wrong paging.

I have tried the following things and didn't work:

$('#grid').data('kendoGrid').dataSource.data([]);

$('#grid').data('kendoGrid').dataSource.read();

Any Ideas ?

Thanks.

8 Answers, 1 is accepted

Sort by
0
Stefan
Telerik team
answered on 04 Jul 2018, 06:13 AM
Hello, El Mehdi,

Thank you for the example.

I tried it, but after I hit the refresh button the data is still correct.

https://www.screencast.com/t/MzmJziFcRQJ9

I assume I missed something, could you please share a short video of the issue and I will gladly assist further.

Regards,
Stefan
Progress Telerik
Try our brand new, jQuery-free Angular components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
0
El Mehdi
Top achievements
Rank 1
answered on 04 Jul 2018, 07:17 AM

Hi Stefan,

Thank you for your response.

Please try this example: https://dojo.telerik.com/OZUTIJEz/2

Scroll drown to activate the infinite scroll functionality at least once. Then, try to hit the refresh button couple of times and check the scroll bar POSITION (with each refresh, the data will be added/duplicated but the number of total will be the same).

Regards,

0
Stefan
Telerik team
answered on 05 Jul 2018, 06:15 AM
Hello, El Mehdi,

Thank you for the clarifications.

I was able to observe it.

It seems that this occurs because clicking the refresh buttons is making a read request and the Grid with endless scrolling is treating this as a request for new data and keeps appending them.

I forward it to the developers' team to investigate if this is indeed an issue or a limitation due to the specifics of the endless scrolling.

I will let you know as soon as I receive the answer.

Thank you in advance for the patience.

Regards,
Stefan
Progress Telerik
Try our brand new, jQuery-free Angular components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
0
Accepted
Stefan
Telerik team
answered on 05 Jul 2018, 11:30 AM
Hello, El Mehdi,

I can confirm that this is an issue with the current version of Kendo UI Grid.

I created an issue in our GitHub repository and forwarded it to our developers for fixing. You can track its progress at:

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

For now, there is no available workaround, if one is found it will be added in the GitHub issue for reference.

Additionally, I updated your Telerik points for bringing this to our attention.

Regards,
Stefan
Progress Telerik
Try our brand new, jQuery-free Angular components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
0
El Mehdi
Top achievements
Rank 1
answered on 05 Jul 2018, 03:25 PM

Hey Stefan,

 

Many thanks for your time and help, glad that this has been taken into consideration

I have tried myself to find a workaround for it, and came up with this fix:

https://dojo.telerik.com/OZUTIJEz/4

 

Kind Regards,

El Mehdi

 

 

0
Stefan
Telerik team
answered on 06 Jul 2018, 06:49 AM
Hello, El Mehdi,

Thank you for sharing this with the Kendo UI community it is highly appreciated.

I added additional points for sharing this.

Regards,
Stefan
Progress Telerik
Try our brand new, jQuery-free Angular components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
0
John
Top achievements
Rank 1
answered on 20 Feb 2020, 06:02 PM
Any update on this? I seem to be experiencing the same.
0
John
Top achievements
Rank 1
answered on 20 Feb 2020, 06:04 PM
Nvm. It would help if I read the previous posts. Thanks
Tags
Grid
Asked by
El Mehdi
Top achievements
Rank 1
Answers by
Stefan
Telerik team
El Mehdi
Top achievements
Rank 1
John
Top achievements
Rank 1
Share this question
or