I have a scenario like after creation of editable template, When author is going to enable it then only after approval that template should get enabled for creating pages. Can you please suggest me the approach if this is possible.
I think you can do it just by customizing the view.
- customize the enable button by createing in apps the same of /libs/wcm/core/content/sites/templates/jcr:content/actions/selection/enabletemplate, in order to make a call to your servlet with run a workflow instance of your workflow model of approval
- if the changes are approved, into a custom workflow step you can set the status to enabled in template path ( e.g. /conf/we-retail/settings/wcm/templates/mytemplate/jcr:content)
1. You just need to go into the path, right click and select "Overlay Node..." this is the standard approach used in order to customize some elements in AEM. After overlay this node, you have multiple choice:
Create a new actions property to send data in a custom servlet
2. Into your servlet you need to run an instace of your custom model by using the following snippet and based on a payload which need to be the path of your template