jeudi 20 mars 2014

Listener for "click" event in Column

Hi,

I'm using extJS 3.4.0 and I'm a beginner. I want to handle the "click" event on a particular column in the Grid.

I was not able to make use of the "listeners" in the Column.



My Code:
var reportColModel = new Ext.grid.ColumnModel({

defaults: {

sortable: true

},

columns: [

........
{id: 'qualifyFlag',

header: 'Qualify Supplier',

dataIndex: 'qualifyFlag',

width: 80,

editor: yesNoCombo,

listeners: { click : function (this,The,rowIndex,e){ alert ('Identified Click'); }},

renderer: Ext.util.Format.comboRenderer(yesNoCombo)

},

..........



Please guide me how to handle the "click" event in this case.

I do not want to use the "cellclick" event on the GridPanel as I will then have to identify the column by "columnIndex". In future if the column I'm referring moves to other position then I've to change the "columnIndex" value.




Aucun commentaire:

Enregistrer un commentaire