I'm having trouble when trying to set a workflow variable by a value a user selects on a form. 

Here's a picture of the workflow section I'm having problems with.

Within the application designer, I create a new variable 'patientAssignment' and have some logic that depends on the value of that variable. I deploy the XPDL file.

Then I create a form and add a select box with a bunch of Value/Label pairs.


I then go to the 'Workflow Variables' within this Property Editor window and add the new workflow variable 'patientAssignment' I created above.

I click OK. I map the activity to the form and publish. When I run through the process, I choose one of the values from the dropdown. I assume that when I choose this value, it gets assigned to the workflow variable 'patientAssignment'.

I complete the task. Unfortunately, my transition logic sends it to the wrong activity because it doesn't think the 'patientAssignment' workflow variable has been set.

To double check this, I look at the process instance and verify that the 'patientAssignment' workflow variable wasn't set.

Any ideas on what I'm missing?

I'm using Joget Snapshot 3.1 Community edition.

Thanks!

-pcw

  • No labels

1 Comment

  1. Problem solved.

    I verified again, through a Beanshell process, that the workflow variable was not being set when completing the activity even though it seemed to be configured correctly in the workflow xpdl and attached to the form field itself (see third pic above.) 

    I deleted the form causing the problem and created a new one in its place, assigning the workflow variable to the field and saved the form. Everything started working as expected.

    I'm not sure how I messed up the previous form, whether I was creating and deleting fields with workflow variables that somehow never got unassigned when the fields were deleted or if something else was just wonky with the form. I'll post again if I can recreate the problem.