04-14-2016 07:28 AM
<startEvent id="startevent1" name="Start" activiti:formKey="swf:submitProcess">
<extensionElements>
<activiti:executionListener event="start" class="org.alfresco.repo.workflow.activiti.listener.ScriptExecutionListener">
<activiti:field name="script">
<activiti:string><![CDATA[
var docSubject = bpm_package.children[0].properties["cm:name"];
var docSubjectArray = docSubject.split("_");
// AT THIS POINT I HAVE AN ARRAY WITH ALL THE INFO I NEED LIKE WHAT GROUP TO BE SENT TO ETC.
]]></activiti:string>
</activiti:field>
</activiti:executionListener>
</extensionElements>
</startEvent>
var gr = docSubjectArray[3];
var g = groups.getGroup("GROUP_"+gr);
//logger.log("\n\n\n GROUP NODE = " + g.groupNode);
execution.setVariable('swf_group',g.groupNode);
//maybe even like this logger.log("\n\n\n GROUP NODE REF = " + g.groupNodeRef);
//var kk = search.findNode(g.groupNodeRef);
//logger.log("\n\n\n KK = "+ kk);
<aspect name="swf:group">
<associations>
<association name="swf:group">
<source>
<mandatory>false</mandatory>
<many>false</many>
</source>
<target>
<class>cm:authorityContainer</class>
<mandatory>false</mandatory>
<many>false</many>
</target>
</association>
</associations>
</aspect>
04-18-2016 08:40 AM
04-20-2016 10:11 AM
Tags
Find what you came for
We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.