Two questions:
Solved! Go to Solution.
Views
Replies
Total Likes
"TEMPLATE EDITOR: This template is not a draft anymore and might already be referenced by one or more pages. Editing the structure will affect all the pages referencing it."
- This is a generic warning message, to inform a template editor that his actions will affect all pages.
Required field
To enforce a mandatory field for all pages generated from this template, it's essential to specify the required attribute for the field within the page component utilized by this template.
Go to the template in CRXDE. look for sling:resourceType attribute on structure node.
- Go to this page component. Drill down to the field that you want to make mandatory. Add the required attribute, based on the documentation for that field. Example: for a textfield (granite/ui/components/coral/foundation/form/textfield), documentation is https://developer.adobe.com/experience-manager/reference-materials/6-5/granite-ui/api/jcr_root/libs/...
OOTB example of mandatory field is Title field for pages
Hi @kayest
1. To edit a template, use tools>General>Template. It's showing you this warning because this template is already enabled and pages are built using this template. If you change anything on this template, it will affect all other pages built using this template.
2. Can you elaborate more on which field you want to make as required? To make a field required you have to add a property required="true". In case you need to make any template properties required, you need to overlay the template properties and set that property required="true"
Hope this helps.
Hi @Avinash_Gupta_ - The field we need to make mandatory is a custom field, but the only choices I have on Tools>General>Template>ThisTemplate are Policy, Lock and Layout. How do I get to where I can add the property you mentioned? Thanks.
"TEMPLATE EDITOR: This template is not a draft anymore and might already be referenced by one or more pages. Editing the structure will affect all the pages referencing it."
- This is a generic warning message, to inform a template editor that his actions will affect all pages.
Required field
To enforce a mandatory field for all pages generated from this template, it's essential to specify the required attribute for the field within the page component utilized by this template.
Go to the template in CRXDE. look for sling:resourceType attribute on structure node.
- Go to this page component. Drill down to the field that you want to make mandatory. Add the required attribute, based on the documentation for that field. Example: for a textfield (granite/ui/components/coral/foundation/form/textfield), documentation is https://developer.adobe.com/experience-manager/reference-materials/6-5/granite-ui/api/jcr_root/libs/...
OOTB example of mandatory field is Title field for pages
Views
Likes
Replies
Views
Likes
Replies
Views
Likes
Replies
Views
Likes
Replies