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

Nested listviews

1 Answer 201 Views
ListView
This is a migrated thread and some comments may be shown as answers.
Dennis
Top achievements
Rank 2
Dennis asked on 13 Jan 2013, 01:23 AM
There is one very real scenario that I often encounter and I'm not sure how to approach it with Kendo.

I have a Datasource that has a complex structure, meaning there are nested complex structures, sometimes going 2 levels. Right now I use a regular data source, and display it with a kendo template. When i do chenges i have to "repaint" the template, since the painted template doesnt seem to notice changes in the underlying MVVM bound item. When i reach the nested elements in the template i use javascript for loops to show them all.

It would be nicer to use a nested type of listview or something, but I'm not sure if it's possible or how to achive it?

I'm also not sure if an hierarchical datasource is applyable since from what I understood that should be used when I have to connect more than one API service call, and I do not have that case. I find the hierarchical datasource documentation lacking, and am not sure of all the scenarios where to use it from it. It would be nice if I could define a model and nest another model inside it. Is that possible?

1 Answer, 1 is accepted

Sort by
0
Alexander Valchev
Telerik team
answered on 15 Jan 2013, 04:57 PM
Hi Dennis,

Kendo DataSource does not support nested data structures. Hierarchical DataSource is not compatible with ListView widget, it is designed to work with the TreeView.

Could you please provide more details about your scenario and if possible a simplified example that demonstrates your current implementation (probably in jsBin/jsFiddle)? Generally speaking Kendo MVVM works with nested data so probably I would be able to suggest a MVVM solution with source and template binding, but I am not sure which of the ListView functionality you use. For example the MVVM does not offer CRUD operations and remote transport out of the box.

Kind regards,
Alexander Valchev
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
Tags
ListView
Asked by
Dennis
Top achievements
Rank 2
Answers by
Alexander Valchev
Telerik team
Share this question
or