View Full Version : GridEditorPanel: "editable: false" ignored for CheckColumn

6 Apr 2010, 1:09 PM
Hello !

I ma making my first EditorGrid and got a checkcolumn working in the grid. But my setting for "editable: False" are ignored!

My column is:

var checkColumn1 = new Ext.grid.CheckColumn
header: 'Enabled',
dataIndex: 'Enabled',
width: 55,
editable: false
I cannot find anything, what I could set in another manner. If I do not specify a checkcolumn, the plain text is shown [true/false].

Any help would be great!


8 Jul 2011, 12:15 PM
The issue looks like an oversight in the ux code, but its pretty easy to fix.

In Ext.grid.Column, getEditor checks editable before returning the editor. But Ext.ux.grid.CheckColumn uses processEvent instead of an editor, and editable is ignored. I've created my own column by extending CheckColumn and have overridden the processEvent function with one that includes the check for editable.

MyCheckColumn = Ext.extend(Ext.grid.CheckColumn, {
processEvent : function(name, e, grid, rowIndex, colIndex){
if (this.editable !== false) {
return MyCheckColumn.superclass.processEvent.apply(this, arguments);
Ext.reg('mycheckcolumn', MyCheckColumn);
Ext.grid.Column.types.mycheckcolumn = MyCheckColumn;

The details here are applicable to 3.3.1, but it looks like a similar fix would work in 4.0.x.

8 Aug 2013, 1:47 AM
Try this:

{header: 'Availability', dataIndex: 'checkvalue', xtype: 'checkcolumn', processEvent: function () { return false; }}

You don't need editable option.