0
votes

I have a node created with sling:resourceType property which has path pointing to a sightly component, where in, this component is used to populate drop down values in a dialog, dynamically.

In my dialog, I have multiple drop downs which I need to dynamically populate.

For every drop down I need to access the same component, but I need to populate different values for each of them.

So is there a way to pass a parameter/a key to that component, from the node which accesses it, so that I will be able to read the parameter in my components html?

1
Can you provide a little more information. I find your use case somewhat difficult to visualise without an example of the content structure and maybe a piece of the dialog (be it a picture or a piece of xml/json)toniedzwiedz
Hi I am doing an implementation using a datasource, similar to the article here helpx.adobe.com/experience-manager/using/….Sai
adobeaemclub.com/… this is one more link which I am referring to.Sai

1 Answers

0
votes

I am not sure why would you need a component to achieve this, You could define different datasource (com.adobe.granite.ui.components.ds.DataSource) implementation and based on the your dropdown invoke these datasource.

Refer to datasource Java Docs here, for sample implementation in touch UI refer to article here and in AEM ACS COMMON, it should work with ClassicUI as well with little modification.

In case you wish to proceed with the existing approach, there is no such straight way to pass one of the component property to the resourceType of the component. What you could do if use selectors with the component inclusion to pass those property values as selectors.