cancel
Showing results for 
Search instead for 
Did you mean: 

How to display selected array as a Node in sap.m.Tree

0 Kudos

Hello Everyone,

We are using sap.m.Tree control to show content in a hierarchical format. Problem we are facing is, it displays every array inside json object as a node.

From below screenshot, whole is a json object and for all the array objects tree node is visible. But only for characteristicGroups data tree node should display.

Is it possible to select which items to display as a nodes ?

Thanks & Regards,

Srinath

Accepted Solutions (1)

Accepted Solutions (1)

voyager
Explorer
0 Kudos

You can specify the arrays that should be displayed by the tree with the parameter arrayNames from JSONTreeBinding.

Try this as your item binding syntax:

items="{path: '/rootItem', parameters: {arrayNames: ['characteristicGroups']}}"
0 Kudos

Thank you so much Nicolas. It worked.

Answers (0)