PDA

View Full Version : Create an Ext.form.Field from a DataView



eztam
7 Oct 2010, 4:58 AM
Hi,
I created a class, which extends Ext.DataView (it contains some checkboxes).
Now I want to create an Ext.form.Field, using this DataView.

So is there any sample or does anyone know, how to do this?

I've got following approach:


var MyDataViewField = Ext.extend(Ext.form.Field, {
initComponent: function() {
this.dataView = new MyDataView({
store: this.store,
...
});
},
afterRender: function() {
// I think this is the right place to render this.dataView
// but how to render it?
// and where?
}
// of course I also have to define getValue/setValue functions
// But what else do I have to define?
});
Thanks eztam!