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

PopOver & hierarchy of items.

1 Answer 59 Views
PopOver (Mobile)
This is a migrated thread and some comments may be shown as answers.
John
Top achievements
Rank 1
John asked on 25 Feb 2013, 08:55 AM
Hi

Is it possible to implement a popover that explores a hierarchy?  The HierarchicalDataSource docs suggest that it's only the TreeView that can handle this, which I'm assuming means that it's not possible to make the popover do this - but I've not tried it out yet. 

If there's any examples of how this might be done, links would be hugely appreciated. 

I'm trying to implement a popover that allows the user to browse a hierarchy, sample screenshot attached.

Thanks,

--
John Clayton

1 Answer, 1 is accepted

Sort by
0
Alexander Valchev
Telerik team
answered on 27 Feb 2013, 08:47 AM
Hello John,

Your understanding is correct, the Hierarchical DataSource component can be used only with the TreeView widget. If you want to implement a Hierarchical ListView, you can use separate Views, ListViews and DataSources. On click of the root ListView, you can filter the DataSource of the child ListView and navigate to it.

There is a code library project that demonstrates the implementation, you can download it from here.

In your case, you should put the corresponding Views inside the PopOver. Instead of using the navigate method of the application, you should use the navigate method of the PopOver's Pane.

function onClick(e) {
    var id = e.dataItem.id,
        listview = e.sender,
        pane = listview.element.closest(".km-pane").data("kendoMobilePane");
 
    type.filter({field: "category", operator: "eq", value: e.dataItem.id});
    pane.navigate("#details");
}

For your convenience I prepared a small example based on the aforementioned code library: http://jsbin.com/iwexir/3/edit

I hope this information will help.

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
PopOver (Mobile)
Asked by
John
Top achievements
Rank 1
Answers by
Alexander Valchev
Telerik team
Share this question
or