cancel
Showing results for 
Search instead for 
Did you mean: 

Send workflow reminder after 3 days from when it was initiated

xiaoting
Champ in-the-making
Champ in-the-making
Hi,

I would like to seek advice on how to set a reminder for a workflow to trigger a single reminder 3 days after it was initiated.

Example,

1st November 2013 - Workflow is triggered. Approver receives a notification to review and approve workflow.
4th November 2013 - Single reminder is sent to Approver if the workflow has not been approved yet.

Help from anyone will be appreciated regarding this. Please kindly provide the approach and steps for this. 

Regards,
XT
2 REPLIES 2

lementree
Champ on-the-rise
Champ on-the-rise
Hi,
like below example, you can define a boundary event to fire after 3 days, in the scripttask you can send mail.


<boundaryEvent id="boundarytimer1" name="Timer" attachedToRef="alfrescoUsertask1" cancelActivity="false">
      <timerEventDefinition>
        <timeCycle>R1/P3D</timeCycle>
      </timerEventDefinition>
</boundaryEvent>
<serviceTask id="alfrescoScripttask1" name="Notify" activiti:class="org.alfresco.repo.workflow.activiti.script.AlfrescoScriptDelegate">
      <extensionElements>
        <activiti:field name="script">
          <activiti:string>

var mail = actions.create("mail");
mail.parameters.to_many = emailToMany;
mail.parameters.from = "notification@raesystems.com";
mail.parameters.subject = "Task Reminder";
mail.parameters.text = "Dear "+ownerFullNames+", \n\n";
mail.parameters.text += "There is one document waiting for your reviewing, please click the link below to proceed.\n";
mail.parameters.text += "Thank you!\n\n\n";
mail.parameters.text += "Task Link: "+hostUrl+"/share/page/my-tasks\n\n";
mail.parameters.text += "Alfresco Workflow Instance";
mail.execute(companyhome);</activiti:string>
        </activiti:field>
      </extensionElements>
    </serviceTask>
   

stéphanieb
Champ in-the-making
Champ in-the-making
Hi Lementree,
I would like to do almost the same thing. The only different point is that I'd need to send a reminder 3 days before the workflow end. Do you know how to make it ?
Thank you Smiley Happy