324
Views
8
Comments
Solved
Dynamic Menu base on DB
Application Type
Reactive
Service Studio Version
11.12.8 (Build 52397)

Hi im new in OutSystems,

I'm trying to create a dynamic menu depending on the filters in DB.

I'm stuck in creating a web block and action that filters the menu.

I try finding a way to use foreach in PageLinks so I can auto-populate the menu.

thank you in advance.

UserImage.jpg
Luis Rocky Dauz
Solution

First, I create 2 blocks(1 for no sub-menu and one for having a sub-menu)

after that in properties of the list widget, I modified the tag div to a and removed all the classes

and it works like a magic 

thanks for all your help

2020-11-13 07-48-15
Khuong Truong

Hi Luis,

If you want to use a forge asset I think you can try this one https://www.outsystems.com/forge/component-overview/202/dynamic-menus

Hope this helps,

Khuong

UserImage.jpg
Luis Rocky Dauz

Hello Khuong,

Your solution is great but I'm looking for a simpler solution or less code.


2024-07-05 14-16-55
Daniël Kuhlmann
 
MVP

Hi,

Welcome to the Outsystems community. If you ask a question it really helps if you also select the application type (Reactive, Traditional, Mobile) as solutions depend on the type of application you are developing.

Regards,

Daniel

UserImage.jpg
Luis Rocky Dauz

Hi,


I edit my question and indicate the application type, Thank you! 

2024-07-05 14-16-55
Daniël Kuhlmann
 
MVP

Fetch the menu data from your (static) entity with the menu options.

Then add a List to your Menu block to iterate the aggregate records, you can use en expression to show the menu option label and a link around it to start the screen URL



UserImage.jpg
Luis Rocky Dauz

your solution is what I'm looking for thanks.

But I have a problem with the UI.

This is my block checking if have a submenu.

The Maintenance Dropdown not working properly the submenu not appearing.

2025-01-15 08-35-04
Vignesh Sekar

Hi luise

please enclose it  with container of all the links, then you can assign the condition to the visible part of that container

Kindly find the attachment for your reference

Thanks,

Vignesh

Screenshot 2021-12-03 130641.png
UserImage.jpg
Luis Rocky Dauz
Solution

First, I create 2 blocks(1 for no sub-menu and one for having a sub-menu)

after that in properties of the list widget, I modified the tag div to a and removed all the classes

and it works like a magic 

thanks for all your help

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.