Expand my Community achievements bar.

How to set a blank default value to a list field under Cloud Services that is dynamically populating options?(Touch-UI)

Avatar

Level 1

Hi,

I have a list field "Add Configuration" which will populate a list of all the config pages under "/etc/cloudservices/myConfiguration". This is basically using the "/libs/cq/cloudserviceconfigs/components/childlist" which is iterating the nodes and appending it to the list.

I tried to overlay this component by adding a blank default value to the list but failed to overlay as this component has a mixinType "granite:finalArea". i.e., it cannot be overylaid or inherited.

Is there a way where I can add a blank value as default value to this list.

Classic UI has a blank value by default which is mismatching with the touch ui cloud services tab.

Thanks in advance!

Regards,

Bhanu Sabbella

3 Replies

Avatar

Level 10

Can you please describe what you did in detail so the community can try to reproduce it.

Avatar

Level 1

Hi,

I have a list field under 'Cloud Services' tab in 'Page Properties'.

This list will populate its options from /etc/cloudservices/myconfigPage under which I have few config pages created.
It will iterate through these config pages getting their properties and show as list options to my list field.

Always, the first of the nodes is shown as the default value.

Requirement: I want a blank value as the default value not the first node option.
For this, I tried to overlay "/libs/cq/cloudserviceconfigs/components/childlist" which has a limitation to be overlaid as I mentioned above.

Please let me know if I can achieve my requirement in any other way.

NOTE: This is working fine in Classic UI. Need the same in Touch UI

Thanks!

Avatar

Level 10

If you can't overlay, which is the case here, then duplicate the code and with the consideration that you may have to refactor it in future. That should work for you.