Get Schduled Page Activation Date in Workflow Email Template | Community
Skip to main content
Leela-Pavan-Kumar
Level 4
January 31, 2023
Solved

Get Schduled Page Activation Date in Workflow Email Template

  • January 31, 2023
  • 2 replies
  • 985 views

We have a workflow that will activate the page upon approval from some users. The workflow sends an email to those users whenever someone requests page publication.

 

When a page activation is scheduled later point then we need to send that date in the email. Are there any OOTB variables just like those mentioned here in Workflow Email Notification Service that I can use in the email template?

 

 

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

Hi @leela-pavan-kumar 

 

We can fetch the exact date and time from comment property found in payload data of the workflow instance. This can be found under 

/var/workflow/instances/../../scheduled_activation_1/data/metaData

 

Logic to fetch the time can be written in custom workflow process step and this step can be added in 

Scheduled Page Activation workflow.

Now as we have date and time we can include that in the email which is getting triggered.

Hope it helps!!

 

Thanks,

Gaurav

 

 

 

2 replies

arunpatidar
Community Advisor
Community Advisor
January 31, 2023

Hi,

Can you try with OOTB property

  • ${event.TimeStamp}, date and time of the event

I have also created a custom template that is here 

https://aemlab.blogspot.com/2019/06/aem-custom-templated-email.html 

Arun Patidar
Leela-Pavan-Kumar
Level 4
January 31, 2023

Hi Arun,

 

I'm expecting a different thing, which is not an event.TimeStamp (returning the time stamp when the workflow is triggered). 

I need the scheduled publish date of the page. Required Value authored in the Activation date is shown in the below image

 

Gaurav_Sachdeva_
Gaurav_Sachdeva_Accepted solution
Level 3
February 1, 2023

Hi @leela-pavan-kumar 

 

We can fetch the exact date and time from comment property found in payload data of the workflow instance. This can be found under 

/var/workflow/instances/../../scheduled_activation_1/data/metaData

 

Logic to fetch the time can be written in custom workflow process step and this step can be added in 

Scheduled Page Activation workflow.

Now as we have date and time we can include that in the email which is getting triggered.

Hope it helps!!

 

Thanks,

Gaurav