PDA

View Full Version : How i can use nested Attributes in a grid template?



Approach
29 Jul 2013, 8:10 AM
Have anybody a idea, how i can use nested attributes in a grid template? I try to use this:

http://docs.sencha.com/extjs/4.2.1/#!/api/Ext.grid.column.Template

But this don't work with my nested hasMany/hasOne attributes. Anybody a idea? :D

tobiu
30 Jul 2013, 8:21 AM
try to use a renderer method for the column(s).

like:


renderer : function(value, metaData, record) {
return value.foo;
}


you also have access to the current record which helps accessing associations. keep an eye on the performance.

best regards
tobiu