cancel
Showing results for 
Search instead for 
Did you mean: 

Value in bpm_package.

irene08
Champ in-the-making
Champ in-the-making
Hi!

Good Day!

Do I need to set a value in bpm_package or does it have a value already? I added this script in bpmn20.xml.

activiti:taskListener event="complete" class="org.alfresco.repo.workflow.activiti.tasklistener.ScriptTaskListener">
<activiti:field name="script">
<activiti:string>
if (bpm_package != null && bpm_package.children != null)
{
var i = 0;
for (i = 0; i &lt; bpm_package.children.length; i++)
{
var document = bpm_package.children;
document.properties["cm:summary"] = "Approved";
document.save();
}
}
</activiti:string>
</activiti:field>
</activiti:taskListener>


Thank you,
Irene
1 REPLY 1

sujaypillai
Confirmed Champ
Confirmed Champ
The bpm_package is the Workflow package containing content being routed through the workflow. So it will by default have a value as the reference to all the content items participating in the workflow. There's no need to set a value explicitly for it.


Thanks,