TreeTable component is a hierarchical table displaying a tree-like structure in the leftmost column. The component is used for entities that have references to themselves. For example, it can be a file system or a company organization chart.

gui treeTable

XML-name of the component: treeTable

gui TreeTable dia

The component is implemented for both Web Client and Desktop Client.

For TreeTable, the hierarchicalDatasource should be set in the datasource attribute of the rows element. Declaration of a hierarchicalDatasource should contain hierarchyProperty attribute – the name of the entity attribute which references the same entity.

Below is an example of component description in a screen XML descriptor:

    <hierarchicalDatasource id="tasksDs" class="com.sample.sales.entity.Task" view="browse"
            select t from sales$Task t
    <treeTable id="tasksTable" width="100%">
            <column id="name"/>
            <column id="dueDate"/>
            <column id="assignee"/>
        <rows datasource="tasksDs"/>

The functionality of TreeTable is similar to a simple Table.