Opened 13 years ago

Last modified 7 years ago

#6251 closed enhancement

DOJO Grid not supporting display of nested objects in JSON data — at Initial Version

Reported by: guest Owned by: sorvell
Priority: high Milestone: 1.3
Component: DojoX Grid Version: 1.0
Keywords: Cc:
Blocked By: Blocking:

Description

The JSON data returned by server (using JSON lib) gives me data which has nested objects.

for e.g.

serverData =    [{"ab":1,"bc":1234567891,"cd":79.23,"de":1100,"ef":2109,"fg":1000,"gh":190,"hi":900, "empDetail":{"firstName":"abc", "lastName":"def"}},{"ab":2,"bc":"1234567892","cd":80.30,"de":1200,"ef":3118,"fg":2000,"gh":290,"hi":1000, "empDetail":{"firstName":"BLAH", "lastName":"BLAHBLAH"}}];

Here, i want to access "empDetail" properties like "empDetail.firstName", "empDetail.lastName".

I am trying to define the grid layout like this:

var empView = {
	cells: [[
	            { name: 'First Name', field: 'empDetail.firstName', width: '10em' },
	            { name: 'Last Name', field: 'empDetail.lastName', width: '10em' }
	       ]]
	     }; 	

I would like to have the grid support nested objects, so i don't have to reformat the JSON data for each nested object and create a individual store for each nested object.

Change History (0)

Note: See TracTickets for help on using tickets.