Thursday 26 September 2013

Extjs, apply class on runtime on actioncolumn of grid

we can apply class on rederer funtion of actioncolumn by checking records property easily as shown below :

 {
                    xtype: 'actioncolumn',
                    width: 70,
                    dataIndex: 'DataIndex',
                    menuDisabled: 'true',
                    text: 'text',
                    sortable: false,
                    fixed: 'true',
                    renderer: function (value, metadata, record) {
                        if (record.get('IsEnabled')) {
                            metadata.tdCls = 'cssClass'
                        }
                    }
                }

No comments:

Post a Comment