I am using JBPM 6.5.0 Kie Workbench on Windows 7. With this workbench I am trying to create a human task form which will has a Selectbox where I will provide its content. With some research, I have learned that I need to create a maven project with a class(implements SelectValuesProvider). This class is:
public class PartyProvider implements SelectValuesProvider { public String getIdentifier() { return "partyListProvider"; } public Map<String, String> getSelectOptions(Field field, String s, FormRenderContext formRenderContext, Locale locale) { Map<String, String> selectOptions = new HashMap<String, String>(); selectOptions.put("1", "1"); selectOptions.put("2", "2"); return selectOptions; } }
I also created a beans.xml file which is totally blank. My pom.xml includes jbpm-form-modeler-api artifact as well. Here is my pom.xml part of dependecies:
<dependencies> <dependency> <groupId>org.jbpm</groupId> <artifactId>jbpm-form-modeler-api</artifactId> <version>6.5.0.Final</version> </dependency> </dependencies>
I have learned that I need to create a jar file from that project then put that jar to claspath. I have put that jar file(under main directory) into modules in wildfly which is installed with Kie WB. Then I have configured standalone-full.xml as
<subsystem xmlns="urn:jboss:domain:ee:4.0"> <global-modules> <module name="my module" /> </global-modules>
Then I have started Wildfly however I will get NoClassDefFoundError for SelectValuesProvider. I don' t know where I am doing wrong. What does it mean by put that jar into classpath? Or is there any documentation to do that. I have searched a lot however couldn' t find any documentation. I want to see my provider where Selectbox' s Dataprovider attribute.
Can you share your thoughts? :/