Custom Action button to show Start Workflow | Community
Skip to main content
mohaninturi
June 21, 2018
Question

Custom Action button to show Start Workflow

  • June 21, 2018
  • 1 reply
  • 1071 views

Hi All,

Can we create custom action button like "Start Workflow" which show Start Workflow modal within the sites.html window itself? We have this option under Page Information when we are editing a page. Any suggestion on how we can achieve this.

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.

1 reply

GaneshM
June 22, 2018

Hi,

You need to overlay sites component. The path for the sites component is "/libs/wcm/core/content/sites/jcr:content/actions/selection".

You can add new option here, however its dialog so you can try adding like below code snippet.

<workflow
   granite:class="aem-ajax-call"
   jcr:primaryType="nt:unstructured"
   sling:resourceType="granite/ui/components/coral/foundation/button"
   text="Start Workflow"
   title="Start Workflow"
   variant="actionBar">

   <granite:data
   jcr:primaryType="nt:unstructured"
   box-confirmation-message=""
   box-failure-message=""
   box-success-message=""
   box-url="/bin/workflow-servlet"/>

</workflow>

We have used AJAX call to invoke, you can use any alternate or suitable for you.

Hope this helps!

Thanks!