On 17/11/10 15:35, Moritz Onken wrote:
Is this actually working?
Hi Moritz,
It does work here.
My store looks something like this:
new Ext.data.JsonStore
({
id:'mystore',
url: /url/for/rest/api
remoteSort:true,
listeners:
{
load: function() { this.loadingBox.hide(); },
beforeLoad: function()
{
this.loadingBox = Ext.Msg.wait('Loading');
},
exception: function(d,s,a,o,r)
{
this.loadingBox.hide();
Ext.Msg.show
({
title:'Error',
msg:'Failed to load grid data',
icon:Ext.MessageBox.ERROR,
buttons:Ext.Msg.OK
});
},
metachange:function(store, meta)
{
var newColumnModel = new
Ext.grid.ColumnModel({columns:meta.fields});
Ext.getCmp(gridId).reconfigure(store, newColumnModel);
}
},
reader: new Ext.data.ArrayReader
({
totalProperty:'total',
successProperty:'success',
root:'data'
})
})
I agree that 'header' is not mentioned as a property of a form.field,
perhaps because it is not and therefore it is just ignored??
However when the ColumnModel is built using 'meta.fields'
Ext.grid.ColumnModel does not ignore the property and therefore fills
out the column headers correctly.
_______________________________________________
HTML-FormFu mailing list
HTML-FormFu@lists.scsys.co.uk
http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/html-formfu