Topic
3 replies Latest Post - ‏2013-10-16T10:21:51Z by goonitsupport
Buzzcut
Buzzcut
10 Posts
ACCEPTED ANSWER

Pinned topic how to access processlog in workflow (justification text)

‏2013-10-13T22:32:46Z |

Is there an example of using this that works? I have done the following.

Registered in scriptframework.properties:

ITIM.extension.Workflow.model.8=com.ibm.itim.script.extensions.ProcessLogExtension
ITIM.extension.Notification.email1=com.ibm.itim.script.extensions.ProcessLogExtension

enRole.properties this is set to false as we don't always want it required:

enrole.justificationRequired=false

ui.properties:

ui.displayJustification=true

 

If I use the example code listed in the documentation:

var list = ProcessLog.getJustificationByProcess(process.guid);

var justification = list.get(0);

I try a simple activity.auditEvent(justification) to verify it works, but it says in the error log "ProcessLog not found". Am I missing something here? Our goal is to display the entered justification so when a manager, etc does an approval they can view the justification entered.

Updated on 2013-10-13T22:38:55Z at 2013-10-13T22:38:55Z by Buzzcut
  • Buzzcut
    Buzzcut
    10 Posts
    ACCEPTED ANSWER

    Re: how to access processlog in workflow (justification text)

    ‏2013-10-13T22:43:04Z  in response to Buzzcut

    I should note as well that I am trying to access this from within an operational workflow (we are doing approval based on business / application role requests). Is this supported?

  • Buzzcut
    Buzzcut
    10 Posts
    ACCEPTED ANSWER

    Re: how to access processlog in workflow (justification text)

    ‏2013-10-14T20:49:17Z  in response to Buzzcut

    I answered my own question. I found the updated IV33033.pdf file with correct example for setup.

     

    The scriptframework.properties should look like this:

    ITIM.extension.Workflow.processLog=com.ibm.itim.script.extensions.ProcessLogExtension

    ITIM.extension.Notification.processLog=com.ibm.itim.script.extensions.ProcessLogExtension

     

    And also add ArrayList:

     

    ITIM.java.access.util=java.util.ArrayList

    • goonitsupport
      goonitsupport
      99 Posts
      ACCEPTED ANSWER

      Re: how to access processlog in workflow (justification text)

      ‏2013-10-16T10:21:51Z  in response to Buzzcut

      What about: -

      var summary =activity.resultSummary;
      var data = process.getActivity(<activityName>).resultDetail;
      activity.auditEvent('Result: ' +summary + ', Response: ' +  data);

       

      This should give you the same result (substitute activityName  with the name of your approval node) without changing scriptframework.properties.