-
1. Re: jbpm-designer. How get variables of current task
tsurdilovic Dec 3, 2012 8:51 AM (in response to kornilovs)You can look on how designer runs the jsonPath expressions to find what the tasks data inputs/outputs and process variables are and then use that info if the plugins you are using allow for auto-completions.
If they don't it might be a little harder to implement, but idk.
Are you willing to contribute your work on this? I think it would be a good addition, and then we could together take a look on how to solve the autocompelte problem.
HTH
-
2. Re: jbpm-designer. How get variables of current task
kornilovs Dec 4, 2012 10:22 AM (in response to tsurdilovic)Thanks for the help.
I found function getCompletionsForForms(token, context, keywords) {...} in file hintjbpm.js. It do all what I want. But I change it little.
I think there (function getCompletionsForForms) is a bug. For both arrays use "i", what call inifinity cycle.
....
for(var i=0;i<childshapes.length;i++){ var csobj = childshapes[i]; if(csobj.resourceId == shapeid) { var datainputs = csobj.properties.datainputset; var dataoutputs = csobj.properties.dataoutputset; var datainParts = datainputs.split(","); for(var i=0; i < datainParts.length; i++) { var nextPart = datainParts[i]; if(nextPart.indexOf(":") > 0) { var innerParts = nextPart.split(":"); maybeAdd('${'+innerParts[0]+'}'); } else { maybeAdd('${'+nextPart+'}'); } ....
-
3. Re: jbpm-designer. How get variables of current task
tsurdilovic Dec 4, 2012 12:01 PM (in response to kornilovs)Nice catch! This was already fixed - https://github.com/droolsjbpm/jbpm-designer/commit/b655f2745e850fc43d0b5330ec33932937aa8d49
-
4. Re: jbpm-designer. How get variables of current task
kornilovs Dec 6, 2012 5:47 AM (in response to tsurdilovic)I decided not use autocomplete, becaus not fined one way add it to editor textarea and jmform textfields. I change jmform textfield on select, and add to TinyMCE plugin, what simple past string with variable name. It's work.
-
5. Re: jbpm-designer. How get variables of current task
tsurdilovic Dec 6, 2012 6:37 AM (in response to kornilovs)Sounds good. Again, if you are planning to contribute your addition let me know. I think community would be interested in something like what you did (do you have any screenshots of it ?)
-
6. Re: jbpm-designer. How get variables of current task
kornilovs Dec 6, 2012 8:02 AM (in response to tsurdilovic)I can send you patch to integrate tinyMCE.
What include:
editor.html
inlinetaskformeditor.js
TinyMCE 3.58(http://www.tinymce.com/index.php) + jmForm2.0.2 (http://sourceforge.net/tracker/index.php?func=detail&aid=1662152&group_id=103281&atid=738747) + my plugin for variables
adapter tinyMCE-> ExtJS (http://blogs.byte-force.com/xor/tinymce/)
screenshot
-
7. Re: jbpm-designer. How get variables of current task
tsurdilovic Dec 6, 2012 8:12 AM (in response to kornilovs)Sounds good (and looks cool too). If you are familiar with github pull requests that would be easiest, if not don't worry, we will figure this out. When you send it, please also send some info about yourself so we can promote you as jBPM community contributor on jBPM blog.
Thanks