getParentId

get the ID of the parent node of the specified item

id getParentId(id id);
ididID of the child node
idID of the parent node

Example

tree = webix.ui({
    view:"tree",
    data: [
        { id:"branch1", value:"The Shawshank Redemption", data:[
            { id:"part1", value:"Part 1" },
            { id:"part2", value:"Part 2" }
        ]}
    ]
});
 
var child = tree.getParentId('part1'); // -> 'branch1'

See also
Back to top
If you have not checked yet, be sure to visit site of our main product Webix javascript framework and page of javascript tree product.