I already have the dropdown list from backend how to place them in Editor label.I am using Java

I already have the dropdown list from backend how to place them in Editor label.I am using Java

Madhavi BhimisettyMadhavi Bhimisetty Posts: 11Questions: 1Answers: 0

I am using Java as a backend
While loading the page I am getting dropdown list like status (active,inactive)
I am using html with thymleaf and Javascript as UI.
While creating table editor how to place that status in field list.

Javascript Code : 


editor = new $.fn.dataTable.Editor( {
    ajax: {
    url: extract_url('/rest/updateType'),
    data: { "_csrf": CSRF_TOKEN,typeName : 'Zones'}
        },
    table: "#zones-search-results",
    idSrc:  'zoneId',
    fields: [ {
            label: "ID :",
            name: "zoneId",
            type:"hidden"
        }, {
            label: "Name :",
            name: "name"
        }, {
            label: "Description :",
            name: "description"
        },
        {
            label: "Status :",
            name: "description",
            type: "select",
        }
    ]
} );

Replies

Sign In or Register to comment.