In grid 'actioncolumn' i displayed an image using 'renderer' like,
image + text
On action column click i am calling some action,
but click event is triggering even click on empty space in grid cell. how to prevent that click on empty space.
how to identify click on link (image+text), not on grid cell empty space.
{
xtype: 'actioncolumn',
width: '17%',
text: 'Display Option',
renderer: function (value, metadata, record) {
var label = '';
if (record.get('status') == 0) {
lable = 'Show';
etadata.style += 'margin-top:10px;cursor:pointer;';
return '<span style="font-size: 14px; color:#3b87de; font-family:arial; margin-left:-3px;">' + '<img src="resources/images/show_msg.png"/>' + label + '</span>'
} else {
metadata.style += 'margin-top:10px;cursor:pointer;';
lable = 'Hide';
return '<span style="font-size: 14px; color:#3b87de; font-family:arial;">' + '<img src="resources/images/hide_fault.png"/>' + label + '</span>'
}
},
handler:function(grid, rowIndex, columnIndex, e){
console.log('handler test');//not triggering
},
listeners: {
click: function ( grid, rowIndex, colIndex) {
console.log('handler test');// triggering
}
}
Thanks