Hello,
Is it possible that the treelist loading looks like the grid loading ?
The treelist loading isn't even following the default height (in options).
A screenshot is attached.
Thank you
3 Answers, 1 is accepted
What you would like to achieve is not supported. Keep in mind that the TreeList will adjust its height after the data is loaded.
Regards,
Iliana Nikolova
Telerik
I have a treelist where all the data is loaded when reading the data. Also I have a functionality where the treelist needs to change its data.
How can I achieve the same loading functionality as in grid?
I need the same functionality of loading as when the tree list is getting the data for the first time. It is exactly as in grid. But after that when I re-read the data the loading is not displayed.
Hi, Dan,
You can manually display the loader when the request starts and then hide it when the request ends.
Dojo:
https://dojo.telerik.com/@gdenchev/AMiJAruL
Please note that the data in the Dojo isn't very large so the loader is hidden very quickly. You can execute the "hiding" functionality in a setTimeout function, so you can see it better.
Hi Georgi,
Thank you for the response.
Now I have a follow-up question: How can I implement this on all tree lists. I should mention that I have around 20 pages that use tree list and some of them already use the events requestStart and requestEnd.
Shouldn't this loading solution have been already implemented inside of the tree list
Hi Dan,
You can put the logic for showing and hiding the Loader in methods and call them in all TreeLists' requestStart and requestEnd event handlers:
requestStart: function() {
showLoader();
},
requestEnd: function() {
hideLoader()
},
...
function showLoader() {
kendo.ui.progress($("div[data-role='treelist']"), true);
}
function hideLoader() {
kendo.ui.progress($("div[data-role='treelist']"), false);
}
Here is the modified Dojo:
Regards,
Nikolay
Hello,
And on the other way, is it possible that the grid loading looks like the treelist loading?
Thanks for your reply.
The opposite requirement is not supported too. What you could try is changing the appearance of the Grid loading via custom CSS - show the text and use the icon from the TreeList loading (dojo).
Regards,
Iliana Nikolova
Telerik