Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

Metadata Schema editor add required for dropdown field

Level 2
Level 2

    I have the requirement to make dropdown field as required property.  So i have overlay the /libs/dam/gui/components/admin/schemaforms/formbuilder/formfields/dropdownfield and updated the dropdownfield.jsp to have required by uncommenting 

    <sling:include resource="<%= resource %>" resourceType="/libs/dam/gui/components/admin/schemaforms/formbuilder/formfieldproperties/requiredfields"/


Then i updated the /apps/dam/gui/coral/components/admin/schemaforms/formbuilder/formfields/dropdownfield/dropdownfield.jsp to include  "requiredfields"

 String[] settingsList = {"labelfields", "jsonfields", "metadatamappertextfield", "disableineditmodefields", "requiredfields", "multivalue", "showemptyfieldinreadonly", "orderedlist"};


I updated the metadata schema editor to  have required for my dropdown field.  But i when i open the document and add all the required field and save it shows me "One or more required field(s) is/are empty." message.

Any ideas why it is not working? I am using aem 6.2 version.


2 Replies
Level 4
Level 4

Hi, Jaya

You overlay dropdownfiled to /apps folder. Can you please check the path that you used to overlay.

Why did created additional coral folder in the path....



I recommend you to overlay without changing the structure....


Level 2
Level 2

Sorry for the confusion.  I have overlay 2 different  paths. 

1. /libs/dam/gui/components/admin/schemaforms/formbuilder/formfields/dropdownfield/  to /apps/dam/gui/components/admin/schemaforms/formbuilder/formfields/dropdownfield

2. /libs/dam/gui/coral/components/admin/schemaforms/formbuilder/formfields/dropdownfield to /apps/dam/gui/coral/components/admin/schemaforms/formbuilder/formfields/dropdownfield