Get/update data from selected TreeView node

2 posts, 0 answers
  1. Lutz
    Lutz avatar
    7 posts
    Member since:
    Feb 2017

    Posted 11 Aug Link to this post

    Hi,

    I have a treeview which gets data from an odata service (Sharepoint REST endpoint) using kendo.data.HierarchicalDataSource.

    I am trying to get the following to work.

     

    When I click on a TreeView node I want to display the complete corresponding node data in a ListView with the ability to edit and update the data like in the ListView demo for editing. Any suggestions?

     

     

     

  2. Stefan
    Admin
    Stefan avatar
    1147 posts

    Posted 15 Aug Link to this post

    Hello Lutz,

    In this scenario, I can suggest using the select event of the TreeView to retrieve the selected node and its text using the text or the dataItem methods:

    http://docs.telerik.com/kendo-ui/api/javascript/ui/treeview#events-select

    http://docs.telerik.com/kendo-ui/api/javascript/ui/treeview#methods-text

    http://docs.telerik.com/kendo-ui/api/javascript/ui/treeview#methods-dataItem

    I made an example demonstrating how to retrieve the node and to set it to the ListView:

    https://dojo.telerik.com/ucUDe

    Then the editing has to be handled programmatically as demonstrated in our demo:

    http://demos.telerik.com/kendo-ui/listview/editing

    I hope this is helpful.

    Regards,
    Stefan
    Progress Telerik
    Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
Back to Top