cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - When posting, your subject should be specific and summarize your question. Here are some additional tips on asking a great question. X

How Can I Add An Output Event to Menus Widgets by Coding?

JasonKwan987
12-Amethyst

How Can I Add An Output Event to Menus Widgets by Coding?

Hello everone!

I want to build a Master like follwing pic.

JasonKwan987_0-1586913524311.png

Click the top menu which is parent menu of the leftside one, the leftside menu will change to appropriate sub items of the top.

I don`t want to build two Master or Mashup  nested. It is better to solve by one Master.

Is there a mathod to add an output Event to Menus Widgets or create a Service for calling one or more sysytem Service as solution?  

 

ACCEPTED SOLUTION

Accepted Solutions
PaiChung
22-Sapphire I
(To:JasonKwan987)

Have you thought of managing visible menu items by using User Groups?

Not sure how dynamic you are grabbing the menu definition, but the exact same table (data source) should be used for both of the menus for the interaction between menus to work.

View solution in original post

4 REPLIES 4
PaiChung
22-Sapphire I
(To:JasonKwan987)

This behavior should be possible with Thingworx menus and the menu widget.

Create your main menu with submenus in Thingworx

Then add two menu widgets, one to display the parent menu items, the other set to display the children.

thanks for reply.

I need to get menu items from database insure that i can add or delete menu labels optionally.

But actions in ThingWorx Composer can't realize function.

So I create a service attemched with Menus Widgets MenuData field and put the Mashup field from top menu to leftside where i pulled a Contained Mashup widget on it.

JasonKwan987_0-1587089851812.png

 

It didn't work.

 

PaiChung
22-Sapphire I
(To:JasonKwan987)

Have you thought of managing visible menu items by using User Groups?

Not sure how dynamic you are grabbing the menu definition, but the exact same table (data source) should be used for both of the menus for the interaction between menus to work.

Yes, I considered it.

And I solved the problem by putting a Tree Grid Widget instead of Menu on the leftside.

I attached Mashup output parameter of the top menu which storage the query condition of the sub menu to a Text field Widget for transferring query-parameter and event to trigger sub menu service.

Then I set it invisible.

It worked and realize the function to add or delete menu items dynamically.

Thanks a lot and I'll test grabbing the menu definition using the same table for both of the menus you suggested.

 

Announcements


Top Tags