emailing workitem comments after workflow approval step

  • 7011080
  • 11-Apr-2012
  • 19-Oct-2012

Resolution

In 4.x,5.x releases, workflows can email workitem's comments after an approval step.
The workflow logic copies workitem comments to the "workItemComments" variable.
The target workflow needs to define/to pass the "workItemComments" variable
to the email template, as demonstrated in this code fragment:

<Workflow ...>
...
<Variable name="workItemComments"/>
...
<Step action="call:sendEmail" icon="Email" name="Send Rejected Email">
<Arg name="template" value="myDummy Role Rejection Notice"/>
<Arg name="lastWorkItemComment" value="ref:workItemComments"/>
<Transition to="Audit Failure"/>
</Step>

The email template then treats the variable as a list-type arg.