PDA

View Full Version : Grid column definition



mgulden
22 Oct 2010, 6:02 AM
Hi,

You will see Ext Designer generated EditGridPanel code below. There is columns which has xtype : gridcolumn or xtype: numbercolumn etc.

In the Api Docs i only see Ext.grid.Column. ?s there any definition belongs to the gridcolumn or numbercolumn ..etc.
are they all same?

Thank you


/*
* File: MyContainer.ui.js
* Date: Fri Oct 22 2010 12:49:12 GMT+0300 (GTB Daylight Time)
*
* This file was generated by Ext Designer version xds-1.0.2.14.
* http://www.extjs.com/products/designer/
*
* This file was manually exported.
*/

MyContainerUi = Ext.extend(Ext.Container, {
width: 400,
height: 250,
initComponent: function() {
this.items = [
{
xtype: 'editorgrid',
title: 'My Grid',
columns: [
{
xtype: 'gridcolumn',
dataIndex: 'string',
header: 'Column',
sortable: true,
width: 100,
editor: {
xtype: 'textfield'
}
},
{
xtype: 'numbercolumn',
dataIndex: 'number',
header: 'Column',
sortable: true,
width: 100,
align: 'right',
editor: {
xtype: 'numberfield'
}
},
{
xtype: 'datecolumn',
dataIndex: 'date',
header: 'Column',
sortable: true,
width: 100,
editor: {
xtype: 'datefield'
}
},
{
xtype: 'booleancolumn',
dataIndex: 'bool',
header: 'Column',
sortable: true,
width: 100,
editor: {
xtype: 'checkbox',
boxLabel: 'BoxLabel'
}
}
]
}
];
MyContainerUi.superclass.initComponent.call(this);
}
});

Condor
22 Oct 2010, 6:20 AM
Read the description of Ext.grid.Column xtype (http://dev.sencha.com/deploy/dev/docs/?class=Ext.grid.Column&member=xtype).

mgulden
23 Oct 2010, 11:59 PM
Thanks Condor.