jQWidgets Forums
Forum Replies Created
Viewing 4 posts - 1 through 4 (of 4 total)
-
Author
-
September 9, 2014 at 11:47 am in reply to: Dropdown column in grid / grid data & dropdown binding to json format Dropdown column in grid / grid data & dropdown binding to json format #59324
I see, thank you very much.
Best RegardsSeptember 9, 2014 at 10:29 am in reply to: Dropdown column in grid / grid data & dropdown binding to json format Dropdown column in grid / grid data & dropdown binding to json format #59316Basically, there is no doubt about this. It just does not behave as expected: http://jsfiddle.net/2opcba3m/
Thanks and regards
September 8, 2014 at 9:06 pm in reply to: Dropdown column in grid / grid data & dropdown binding to json format Dropdown column in grid / grid data & dropdown binding to json format #59279Does it mean it’s not possible to use the Dropdownlist with a “number” array? My Json Data for the dropdown values is formated as numbers, not as string.
Thanks and regards.September 7, 2014 at 10:49 am in reply to: Dropdown column in grid / grid data & dropdown binding to json format Dropdown column in grid / grid data & dropdown binding to json format #59204I wonder how to use this with numbers. The Dropdownlist does not show up numbers, if I change the locations to numbers:
// number data var data = [{ "id": "1", "name": "John", "country": "USA", "location": 0, //"New York", "locations": [ 0, //"New York", 1, //"Boston", 2] //"Los Angeles"] }, { "id": "2", "name": "Robert", "country": "UK", "location": 3, //"London", "locations": [ 3, //"London", 4, //"Cardiff", 5] //"Liverpool"] }]; // prepare the data var source = { datatype: "json", localdata: data, datafields: [{ name: 'name', type: 'string' }, { name: 'country', type: 'string' }, { name: 'location', //type: 'string' }, { name: 'locations', }], id: 'id', }; var dataAdapter = new $.jqx.dataAdapter(source); $("#jqxgrid").jqxGrid({ width: 750, source: dataAdapter, columnsresize: true, editable: true, columns: [{ text: 'Name', datafield: 'name', width: "33%" }, { text: 'Country', datafield: 'country', width: "33%" }, { text: 'Location', datafield: 'location', width: "34%", columntype: "dropdownlist", initeditor: function (row, cellvalue, editor, celltext, cellwidth, cellheight) { editor.jqxDropDownList({ source: dataAdapter.records[row].locations }); } }] });
Thanks
-
AuthorPosts
Viewing 4 posts - 1 through 4 (of 4 total)