1
0
-1

Here the e.g of returned data:

{
"data": [
{
"id": "7ea",
"title": "log set Ingress Authentication",
"status": "closed",
"source": "abc",
"alerts": [
{
"type": "Custom",
"description": " defined.",
"first_event": "2018-12-16T08:10:42.068Z"
}
],
"created": "2018-12-16T08:17:18.046Z"
}

And following is the configuration for JSON OBJECTNAME under: PLUGIN CONFIGURATION→STORE TO FORM

data.id

data.title

data.status

data.source

data.alerts.type

data.alerts.description

data.alerts.first_event

data.created

I am getting the data into database table except the alerts: type, description, first_event. Could someone advise how to configure this nested array?

    CommentAdd your comment...

    1 answer

    1.  
      1
      0
      -1

      Hi Manjeet,

      I just had a look at the source code at specifically at line 271 https://github.com/jogetworkflow/jw-community/blob/7.0-SNAPSHOT/wflow-core/src/main/java/org/joget/apps/app/lib/JsonTool.java#L271

      {
          "data": [{
              "id": "7ea",
              "title": "log set Ingress Authentication",
              "status": "closed",
              "source": "abc",
              "alerts": [{
                  "type": "Custom",
                  "description": " defined.",
                  "first_event": "2018-12-16T08:10:42.068Z"
              }],
              "created": "2018-12-16T08:17:18.046Z"
          }]
      }


      The current implementation is not expecting to hit an array (alerts) inside the first array (data).

      Alternatively, you can consider using the Form API Builder and get the external system to call upon Joget's to insert the data in.

      Thanks.

      Hugo

        CommentAdd your comment...