List is not properly loading in bonita ui select widget

1
0
-1

I am trying to show list values in select widget in bonita ui using process variable but its not working .I am using Bonita BPM Community Edition
Version : 7.3.3 Studio. Its showing values character by character not as string values.It should show values like:

some 1
some 2
but its displaying values like:
[
s
o
m
e

1
,
....
My whole process is given at link.
https://uploadfiles.io/4c1161

1 answer

1
0
-1

Hi,

Yes it's weird, the REST Api is returning a String representation of the List.

As for a workaround, I managed to make it work by using an intermediate variable (Javascript expression) that takes the value returned by the REST Api and convert it into an Array:

  1. var slicedString = $data.listval.value.slice( 1 );
  2. slicedString = slicedString.slice(0, -1);
  3. var splitString = slicedString.split(",");
  4. return splitString;

Cheers

Notifications