summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Branson <andrew.branson@cern.ch>2014-10-16 10:32:23 +0200
committerAndrew Branson <andrew.branson@cern.ch>2014-10-16 10:32:23 +0200
commitf7e0e98b907498a9f186f66a73bcf5570f75e989 (patch)
tree1f105348afbfeac17f6e14d52eccb4ed26eb9a80
parentb52234221dc08f073249fcae5883ec468211fe7b (diff)
AddMemberToCollection call wasn't passing in the Version property
-rw-r--r--src/main/resources/boot/SC/SetWorkflow.xml8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/main/resources/boot/SC/SetWorkflow.xml b/src/main/resources/boot/SC/SetWorkflow.xml
index 3dd5910..0b4b68a 100644
--- a/src/main/resources/boot/SC/SetWorkflow.xml
+++ b/src/main/resources/boot/SC/SetWorkflow.xml
@@ -2,7 +2,8 @@
<cristalscript>
<output name="errors" type="org.cristalise.kernel.scripting.ErrorInfo" />
<script language="javascript" name="SetWorkflow"><![CDATA[
- // Fetch the requested name from the outcome field
+ importClass(org.cristalise.kernel.utils.CastorHashMap);
+ // Fetch the requested name from the outcome field
var wfDefName = job.getOutcome().getField("WorkflowDefinitionName");
var wfDefVersion = job.getOutcome().getField("WorkflowDefinitionVersion");
@@ -40,9 +41,12 @@
}
// add the new member
- var params = new Array(2);
+ var params = new Array(3);
+ var newProps = new CastorHashMap();
+ newProps.put("Version", wfDefVersion);
params[0] = "workflow";
params[1] = wfItem.getPath();
+ params[2] = agent.marshall(newProps);
agent.execute(item, "AddMemberToCollection", params);
]]></script>