-
1. Re: Tasks definition extension points
krisverlaenen Jun 27, 2011 12:49 PM (in response to mpiraccini)If you want to define them as custom attributes, you would have to extend the jBPM code, yes.
It's probably a lot easier to just define an additional task parameter that contains your data. So it will be similar to properties like Comment and Priority, but the data will simply be stored as a task parameter, as part of the ioSpecification of the userTask. This would not require you to extend the code itself, as tasks allow you to define additional task parameters out of the box. You can then use this parameter in your handler by doing workItem.getParameter(name).Assuming you're defining your processes in XML, I would suggest taking a look at how properties like Comment and Priority get saved in the BPMN2 XML, so you can do something similar for your parameter.
Kris
-
2. Re: Tasks definition extension points
free Oct 24, 2011 10:10 PM (in response to krisverlaenen)hi,kris
I edited jbpm-bpmn2-5.1.0.Final.jar\META-INF\BPMN2SemanticModule.conf,add codes:
myuserTask=org.drools.bpmn2.xml.MyUserTaskHandler .MyUserTaskHandler.java extends TaskHandler,but bpmn file could not find myuserTask view.
So,how can I set conf file to present myuserTask view.
-
3. Re: Tasks definition extension points
free Oct 25, 2011 2:45 AM (in response to free)why is it wrong when I do this
[
"name" : "myUserTask",
"parameters" : [
"ActorId" : new StringDataType("kris"),
"Content" : new StringDataType()
],
"displayName" : "My User Task",
]