[jboss-user] [JBoss Seam] - How to set a variable to a taskInstance
mlsreekanth
do-not-reply at jboss.com
Mon Aug 21 08:46:08 EDT 2006
Hello all,
I a trying to set a variable to a taskInstance where that variable is declared as required in the taskcontroller of the process.
When i created this variable as Outjected and BUSINESS_PROCESS scoped, it is not being updated by an assignment rather than the initialization.
But when i use the TaskInstance instance and set variable , it is being set.
I am pasting the twi implementations, please help me
//OUTJECTION
Decision Variable has setters and getters where these being set from a Form
@Out(scope=ScopeType.BUSINESS_PROCESS,value="decision",required=true)
String decision="Accepted";
@EndTask(transition="ReviewCompleted")
public String approve() {
System.out.println(" It is Decided to " + decision);
return "registrationslist";
}
//USING DIRECT TASK INSTANCE
Decision Variable has setters and getters where these being set from a Form
String decision="Accepted";
@EndTask(transition="ReviewCompleted")
public String approve() {
System.out.println(" It is Decided to " + decision);
taskInstance.setVariable("decision", decision);
taskInstance.addComment("Comment is added in reviewcompleted transion");
return "registrationslist";
}
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3966432#3966432
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3966432
More information about the jboss-user
mailing list