I found that I am developing extjs applications (rally applications), which sometimes I need data from a record in a record.raw file, and not in a record.data file. What is the difference between the two, and why could this be so?
EDIT is an example of adding (a column for a sortable parent is one of my other questions)
{text: 'Parent', dataIndex: 'Parent', doSort: function(state) { var ds = this.up('grid').getStore(); var field = this.getSortParam(); ds.sort({ property: field, direction: state, sorterFn: function(v1, v2){ if (v1.raw.Parent) { v1 = v1.raw.Parent.Name; } else { v1 = v1.data.Name; } if (v2.raw.Parent) { v2 = v2.raw.Parent.Name; } else { v2 = v2.data.Name; } return v1.localeCompare(v2); } }); }, renderer: function(value, meta, record) { var ret = record.raw.Parent; if (ret) { return ret.Name; } else { meta.tdCls = 'invisible'; return record.data.Name; } } },
source share