Form input does not change


Hello. I am trying to create app for creating and modifying business vars (something like simple registry) and i have problem with modifying data in inputs.

I have 2 processes - first for creating, second for modifying business vars.

The problem is in second one:

So here i have list of all existing entries:
, when i press second button i take persistanceId of the record and pass it to my second (record edit) page.

In this second page i take record entry by its persistance id, fill inputForm JSON variable with it and bind my form inputs with it data.

Javascript for filling JSON inputForm variable:

$data.formInput.newName = $[0].name
$data.formInput.newAlpha = $[0].alpha2Code
$data.formInput.contryId = $data.countryId
return "hello";

And my idea is to call instantiation of edit process, and modify business variable with inputed data. The problem is - i cant modify my inputs.

I've tried everything - but if i bind my inputs with JSON variable with existing business variable data - i just cand type there anything. Nothing helps -

So the main question is - what can i do to fix it.

The second question is (it is not referenced to main problem) - can i somehow add custom event listeners for page elements (for example - perform some action just before onclick event for submit button) and if i cant - how to do it?

I tried to create instantiation form for edit process via bonita bpm studio (in Execution tab of my process pool) and faced pretty much the same problem:

I get record by its persistance id by external api variable:


then set formInput values with it:

$data.formInput.newName = $[0].name
$data.formInput.newAlpha = $[0].alpha2Code
$data.formInput.contryId = $data.countryId
return "hello";

and after that i cant type anything in my form inputs. Still have no idea why and how to overcome this problem


Submitted by vitiellom on Wed, 11/22/2017 - 10:39


bumped into the same problem. It seems that setting the formInput in this way does not allow any further modification of the values from the UI.
A workaround would be to use the value property of the input field directly without using a variable. For example to set the input field of the newName with the value from $[0].name, you should set its value property to $[0].name. In that way the field gets the value $[0].name as default value and you are still able to modify it from the UI. However, you will also have to modifiy the formOutput accordingly I presume.


No answers yet.