you can create a dynamic css class for GridView in extjs without hard coding the CSS class inside the stylesheet, e.g.
DEFAULT_ROW_COLOR = '#E0E0E0';
...
var gridview = new Ext.grid.GroupingView({
forceFit : forceFit,
hideGroupedColumn : true,
showGroupName : false,
groupTextTpl: '{text}',
getRowClass : getRowClassFunc
});
var getRowClassFunc = function(record, rowIndex, rowParams, store) {
if (rowIndex == 1 ) {
}
if (rowIndex > 1) {
}
};
source
share