1
0
-1

Hi Guys,

 

Hope you can help.

 

I need to resolve the Previous Activity's (ActivityID).

 

I can do this in a Bean Shell Tool, but i am only able to resolve the current ActivityID as per below.

import org.joget.workflow.model.service.*;
WorkflowManager wm = (WorkflowManager) pluginManager.getBean("workflowManager");
wm.activityVariable(workflowAssignment.getActivityId(),"wfactivityId", "#assignment.activityId#");

 

My objective is to embed a hyperlink with the URL containing the previous ActivityID.

 

Thanks in advance.

 

Regards,

 

Ernest.

 

 

    CommentAdd your comment...

    2 answers

    1.  
      1
      0
      -1

      Hi, looking at the WorkflowManager API at https://github.com/jogetworkflow/jw-community/blob/5d71cfabb90767e9ee9db461a80bb221859d2fea/wflow-wfengine/src/main/java/org/joget/workflow/model/service/WorkflowManager.java#L165, you could try calling the getActivityList method to retrieve the list of activities for a process to look for the previous completed one.

       

       

        CommentAdd your comment...
      1.  
        1
        0
        -1

        Hi Anders,

        Great, thanks, i will investigate this option.

        Regards,

        Ernest

          CommentAdd your comment...