kendo ui data grid - firebase -
i'm using kendo ui data grid firebase (rest json response). structure can contain multiple objects. however, these objects not in standard array format. see json file below:
{ "users": { "contactdetails": { "email": "johnlittle@email.com" }, "firstname": "john", "id": 1, "surname": "little" } }
i able read firstname , surname onto grids column cannot email object.
this schema definition:
schema: { model: { fields: { id: {type: "number"}, firstname: {type: "string"}, surname: {type: "string"}, email: {type: "string"} } } }
as far know, u can not specify nested object schema model definition. 1 way can use column template email column.
columns: [ { field: "firstname", title: "firstname" }, { field: "surname", title: "surename" }, { title: "email", template: "#= data.contactdetails.email #" }, ],
Comments
Post a Comment