Adam Bach [https://community.jboss.org/people/heathcliff] created the discussion

"jBPM WorkItemHandler problem: when Object is passed as param it's transformed 
to String."

To view the discussion, visit: https://community.jboss.org/message/733763#733763

--------------------------------------------------------------
Hi,

I'm passing an object of type Task to WorkItemHandler implementation and it 
lands in params map as after invoking toString method on my obejct.
WID definition:
import org.drools.process.core.datatype.impl.type.StringDataType;
import org.drools.process.core.datatype.impl.type.FloatDataType;
import org.drools.process.core.datatype.impl.type.ObjectDataType;
[
  // the CreateProject work item
  [
    "name" : "TaskTime",
    "parameters" : [
      "host" : new StringDataType(),
      "task" : new ObjectDataType(),
      "date" : new ObjectDataType(),
      "time" : new FloatDataType(),
    ],
    "displayName" : "TaskTime",
    "icon" : "icons/taskTime.png"
  ]
]

When I double click on my domain specific node on designer I get a window where 
I can provide values for parameters. So for task param I have given #{taskObj} 
and instead of an actual object I have received a String version of this 
object. The workaround is to explicitly map this param in properties view, but 
the idea was to give users UI for setting those values in more pleasent way.

ANOTHER problem is that when I set some values to my custom node than 
Properties view is not changing accorgingly to my my node type. Meannig when I 
click on some node than the Properties view is updated to show those props. 
Than when I click to my TaskTime node than Properties view has only those props 
which ware available for previous node, and if some props are common for both 
node than values for tham are updated with ne values. So when I click on my 
TaskTime node I can see the host,task,date,time properties, nor I can see on 
Entry and on Exit action properties. Furthermore If previosus node had such 
properties than I can see them for TaskTime node but when I update them than 
they are updated for that previosud node.

Can someone confirm those issues? Any help on workarounds?
--------------------------------------------------------------

Reply to this message by going to Community
[https://community.jboss.org/message/733763#733763]

Start a new discussion in jBPM at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2034]

_______________________________________________
jboss-user mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/jboss-user

Reply via email to