In remote data binding, we need to use the self-referential data structure. And need to enable the idMapping, parentIdMapping and hasChildMapping property of the treegrid.
- ID Field: This field contains unique values used to identify nodes. Its name is assigned to the idMapping property.
- Parent ID Field: This field contains values that indicate parent nodes. Its name is assigned to the parentIdMapping property.
- HasChildMapping: This property maps the field name in data source, that denotes whether current record holds any child records. This is useful internally to show expand icon while binding child data on demand.
For more information about the TreeGrid component, refer to this documentation.
For more information about TreeGrid's remote data binding feature, refer to this documentation