Create array of objects in microflow

0
Hi Team, Am using highchart to show graph. to make data dynamic i want to create below object in microflow {   "xAxis": {     "categories": [       "DTS",       "DASS",       "Others"     ], "labels": {                 "style": {                     "fontSize":"13px",                     "fontWeight":"Bold"                 }             }   },   "series": [     {       "name": "Review",       "data": [         1,         0,         4       ]     },     {       "name": "Feasibilty",       "data": [         5,         7,         3       ]     },     {       "name": "Estimation",       "data": [         5,         3,         2       ]     },     {       "name": "Offer Submitted",       "data": [         5,         7,         3       ]     }   ] }   Can some one guide me how to create this data using microflow.   Thanks  Ashwath 
asked
1 answers
0

Hi,

  • Create the "xAxis" object with the "categories" and "labels" attributes. To do this, add two string attributes to the "xAxis" object entity and set their values accordingly. You can use the "Set attribute" action to set the values for "categories" and "labels."
  • Create a new entity for the "series" object. Add two attributes to this entity: a string attribute called "name" and a list attribute called "data" of type Integer.
  • Now, you will need to create four "series" objects (Review, Feasibility, Estimation, and Offer Submitted) and populate their data lists. For this, use a loop to create the four series objects, and inside the loop, set their "name" attribute and the "data" attribute values accordingly.
  • Finally, connect the "xAxis" object with the list of "series" objects. To do this, you can create a one-to-many association between the "xAxis" object and the "series" object.
  • Your microflow should now generate the desired dynamic object. Make sure to execute the microflow whenever you want to show the graph with the dynamic data.
answered