cancel
Showing results for 
Search instead for 
Did you mean: 

Create dynamic controls from JSON Response

Former Member
0 Kudos

I have a requirement to create a group of checkbox with lebels in a page from JSON response.

The JSON response is

{

    "data": [

        {

            "CodeStatus": "Red"

        },

        {

            "CodeStatus": "Orange"

        },

        {

            "CodeStatus": "Green"

        },

        {

            "CodeStatus": "Yellow"

        }

    ]

}

the  design is:

the box is vertically scrollable, as it can have more color codes.

Can anyone suggest how to design the above?

If one can provide the implemantation code, that would be very good as I have very time to implement it.

Accepted Solutions (1)

Accepted Solutions (1)

jmoors
Active Contributor
0 Kudos

Have a look at templates and for more complex scenarios factory functions, which give you the ability to dynamically create controls from model data.

SAPUI5 SDK - Demo Kit

Regards,

Jason

Answers (1)

Answers (1)

former_member182862
Active Contributor
0 Kudos

Hi Shashi

Does this help?

Example

-D

Former Member
0 Kudos

Thanks Dennis,

Can the header be removed from the table?

I do not need the header.

former_member182862
Active Contributor
0 Kudos

Like this?

Changed

-D