I have configured the workflow so that when my workitem reaches a certain status, i can run a script that would automatically resolve all comments in that workitem.
This is my script below
Code: Select all
var workitem = workflowContext.getTarget();
var unresolved = workitem.getComments(false);
var iterator = unresolved.iterator();
var comment = iter.hasNext();
The problem is that when i select the transition " Perform action Resolve Comments " that i have setup for this script, nothing happens.
Any thoughts ? Or maybe any other approach to solving comments ( even in bulk ) ?
Thanks for your help !