PDA

View Full Version : GroupingView getRowClass not working?



mobile_suit_zero
14 Aug 2008, 2:01 PM
Hi,

Does anybody know how to use the getRowClass to modify certain rows in the EditorGridPanel with the grouping view??



Thanx,


this.view = new Ext.grid.GroupingView({
enableRowBody: true,
forceFit:true,
showGroupName: false,
// hideGroupedColumn: true, // enable this will cause an issue with group column
groupTextTpl: '{text} ({[values.rs.length]} {[values.rs.length > 1 ? "Items" : "Item"]})',
getRowClass: this.applyRowClass,
}),


Ext.extend(qadb.testcase.tcDetail,Ext.grid.EditorGridPanel, {

applyRowClass: function(record, rowIndex, p, ds) {
alert('here');
//if (this.showPreview) {
// var xf = Ext.util.Format;
// p.body = '<p>' + xf.ellipsis(xf.stripTags(record.data.description), 200) + '</p>';
return 'x-grid3-row-expanded';
//}
//return 'x-grid3-row-collapsed';
},
:
:

MichaelOstrovsky
22 Jan 2009, 5:46 AM
I have same problem.
anyone ?

Animal
22 Jan 2009, 5:48 AM
In the Grid config



viewConfig: {
getRowClass: function() {}
}


Or in the GridView config just opke a function in.

easy as that