ExactTarget/fuelux — pull request #237 by JoeHetfield (2013-08-01 01:55:54+00:00)
Title: add nested property support to datagrid

say I have a "me" object:
{
name: "JoeHetfield",
age: 39,
pet: {
name: "Back Jack",
age: 5
}
}

then I can use datagrid like this:

// INITIALIZING THE DATAGRID
var dataSource = new StaticDataSource({
columns: [
{
property: 'name',
label: 'My Name',
sortable: true
},
{
property: 'age',
label: 'My Age',
sortable: true
},
{
property: 'pet.name',
label: 'Pet Name',
sortable: true
},
{
property: 'pet.age',
label: 'Pet Age',
sortable: true
}
],
data: dataOfPersonAndTheirPet,
delay: 250
});

$('#MyGrid').datagrid({
dataSource: dataSource,
stretchHeight: true
});

property could nested in many level, until property path hit null or undefined, then the result will be "null".
could be useful, I think.