Skip to Content
avatar image
Former Member

Display complex tree with node relationships

Hello Community,

I am working on a way to display rather complex relationships between bill of materials (BOMs). So when the user enters a material, it shows the BOM of the material and then, in a relationship, the BOMs of the component, and so forth..

This is a picture I found on Google that displays the general idea:

I am looking for a way to print such a tree on the screen, preferably with controls (to handle double clicks, maybe change color of nodes, ..)

The display you may know from transaction SQVI (to display joins between tables) is a little bit too complex (as we only need to display little information in the node itself) but also gives another idea about what I'm looking for. (I think that is CL_QUERY_JOIN_CNTRL / CL_QUERY_JOIN_DATA)

Classes like CL_SIMPLE_TREE_MODEL however don't seem complex enough, as we only have the "list tree" display (as far as I know).

Could class CL_FPM_TREE_RENDERING be something to display it like mentioned above? I haven't found example programs for this though.

Thanks a lot for your help!

Rick

EDIT: I found some example programs such as HIER_BO2 / HIER_BO1 (which use function CNET_GRAPHIC_HIERARCHY to print the hierarchy) / GRSTRU00 that in a way outline what I want to do. However, I realize, that one of the difficulties with displaying hierarchies for BOMs is, that a component can have multiple parent nodes (a screw, for example can be used in multiple products). That does not seem possible with those functions.

Add comment
10|10000 characters needed characters exceeded

  • What are the requirements for double clicks? Will it be okay with a web solution? Eg. https://www.npmjs.com/package/viz.js is very easy to use for drawing trees

  • Former Member

    Hi Lars, thanks for your reply.

    Is there (an easy) connectivity to a SAP system? Because we have all the information in SAP and the system is supposed to draw the trees automatically based on the BOMs we currently have in the system, the user is not supposed to do that manually.

    Double-Clicks are really rather nice to have. I'd assume if such a solution exists in SAP, we can also put in an event handler.

    Thanks, Rick

  • Get RSS Feed

0 Answers