Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
55
iggrid picklist not rendered when datasource set to webapi
posted

Hi,

have this problem that when use static json data for datasource then picklist is getting rendered and  show up as combobox

but when I use same data from webapi picklist doesn't show up and related column is empty without combobox.

 $("#grid1").igGrid({
                width: '100%',
                columns: gridcolumns,
                dataSource: dataURL,
                features: [
                ],
                rendered: function (evt, ui) {
                    tmpl = "<div id=grdpicklist_${ID}></div>";
                    $('#grid1').igGrid('setColumnTemplate', 'Company', tmpl);
                },
            });

  dataSource = $("#grid1").igGrid("option", "dataSource");
            $.each(dataSource, function (index, row) {
                $("#grdpicklist_" + row.ID).CustomPickList({
                    'id': 'grdpicklist_' + row.ID,
                    'dataSource': PickListData,
                    'contentType': 'application/json',
                    'valueKey': 'ID',
                    'textKey':  'Company',
                    'selected': row.ID,
                    'externalColumns': PickListCols,
                    'module': 'Project',
                    'callback': onGridPicklistSelection
                });
            });

what can be a problem here? When I switch data source to local json array it works.

thanks

Parents Reply Children
No Data