AnsweredAssumed Answered

Timer isnt working, Help!

Question asked by bucklao on Jul 14, 2008
Latest reply on Aug 4, 2009 by cheffilet
Hello,

I've implemented a timer in my workflow and it doesnt seem to be working.  What im trying to do is when a user approves a task then it moves to the DeptHead group task.  After a certain time of which there is no response an email notification gets triggered to the DeptHead group reminding them of the task.  Hopefully someone can shed some light on what im missing.

Here is my code:
<task-node name="deptHead review">
      
      <task name="scwf:deptHeadReview" swimlane="deptHead">
      <timer name="thirdPartyTimer" duedate="1 minutes">
      <action class="org.alfresco.repo.workflow.jbpm.AlfrescoJavaScript">
      <script>
            {
            var mail = actions.create("mail");
      mail.parameters.to = "sangbouasya@stancounty.com";
        mail.parameters.subject = "Timer is working!!!";
        mail.parameters.from = "alfresco@alfresco.com";
        mail.parameters.template = companyhome.childByNamePath("Data Dictionary/Email Templates/wf_reject_admin.ftl");
        mail.parameters.text = "some text, in case template is not found";
        mail.execute(bpm_package);
            }
            </script>
      </action>
      </timer>  
      </task>
      <transition name="approve" to="end1">
      <action class="org.alfresco.repo.workflow.jbpm.AlfrescoJavaScript">
            <script>
            {
            var mail = actions.create("mail");
      mail.parameters.to = "sangbouasya@stancounty.com";
        mail.parameters.subject = "Your P.O. Contract has been Approved by the Department Head";
        mail.parameters.from = "alfresco@alfresco.com";
        mail.parameters.template = companyhome.childByNamePath("Data Dictionary/Email Templates/wf_reject_admin.ftl");
        mail.parameters.text = "some text, in case template is not found";
        mail.execute(bpm_package);
            }
            </script>
            </action>
      </transition>
      <transition name="reject" to="admin review"></transition>
   </task-node>

Outcomes