1. 程式人生 > >Ext.grid.panel 改變某一行的字型顏色

Ext.grid.panel 改變某一行的字型顏色

grid.getStore().addListener('load', handleGridLoadEvent);

    function handleGridLoadEvent(store, records) {
        var gridCount = 0;
        store.each(function (r) {
            if (r.get('disorderlyStatusStr') == "回溯點亮") {
                var length = disorderly.getView().getRow(gridCount).cells.length;
                
for (var i = 0; i < length; i++) { disorderly.getView().getRow(gridCount).cells[i].style.color = 'red'; } } gridCount = gridCount + 1; }); }