Expand my Community achievements bar.

SOLVED

Extract dynamic values as drop-down in AEM Content Fragment Model

Avatar

Level 1

Reqiurement:

I wanted to add a dynamic drop-down field in AEM Content Fragment Model. But while creating fragment, it need to show me the possible list of values populated in the drop-down from a back-end API.

I already exlored acs commons generic list option but that again seems to be static. In case, if there are future changes to the content fragment model, then there is a need to update generic list again.

 

Is there a possible approach to populate the JSON from API in a content fragment model?

Topics

Topics help categorize Community content and increase your ability to discover relevant content.

1 Accepted Solution

Avatar

Correct answer by
Community Advisor

Hi, 

When you said you explore the "generic-list" option are you referring to this blog? https://blogs.perficient.com/2019/09/06/dynamic-dropdowns-in-aem-content-fragments/ . This blog clearly explains how to create a dynamic dropdown, you just need to adjust the logic to bring the options from your API instead of the "generic-list".

 

Hope this helps



Esteban Bustamante

View solution in original post

2 Replies

Avatar

Correct answer by
Community Advisor

Hi, 

When you said you explore the "generic-list" option are you referring to this blog? https://blogs.perficient.com/2019/09/06/dynamic-dropdowns-in-aem-content-fragments/ . This blog clearly explains how to create a dynamic dropdown, you just need to adjust the logic to bring the options from your API instead of the "generic-list".

 

Hope this helps



Esteban Bustamante

Avatar

Administrator

@ssridharcse Did you find the suggestions from users helpful? Please let us know if you require more information. Otherwise, please mark the answer as correct for posterity. If you've discovered a solution yourself, we would appreciate it if you could share it with the community. Thank you!

 



Kautuk Sahni