1. #1
    Sencha Premium Member aiky.cc's Avatar
    Join Date
    Aug 2012
    Location
    Novosibirsk, Russia
    Posts
    26
    Vote Rating
    0
    aiky.cc is on a distinguished road

      0  

    Default 4.2.0 grid Loading and Grouping

    4.2.0 grid Loading and Grouping


    Today I was testing new 4.2.0 bufferedrenderer feature - it`s working good, thank you, but 2 notes:

    1. Loading grid:

    4.1.3
    loading413.png

    4.2.0
    loading420.png

    2.Grouping grid:

    4.1.3
    group413.png

    4.2.0
    group420.png

    Code:
    var store = Ext.create('Ext.data.Store',{
      'autoLoad':true,
      'fields':[...
       {'name':'group','convert':
         function(value,record) {
           if(record.get('state_id') != 1){
             var t = record.get('time_from');
             var d = new Date(Ext.util.Format.date(record.get('time_from'),'Y-m-d'));
             return d;
           }
           return 'new';
         }
       },
       {'name':'time_from','type':'date','dateFormat':'Y-m-d H:i:s'},
       ...
     ],
     ...
     'groupField':'group',
      'proxy':{...},
      'listeners':{...}
     }        
    });
    
    var grid = Ext.create('Ext.grid.Panel',{
      'layout':{...},
      'selModel':Ext.create('Ext.selection.RowModel',{
        'mode':'multi'
       }),
       'flex':1,
       'border':0,
       'store':store,
       'tbar':{...},
       'columns':[
         ...
         {'text':'time_from','dataIndex':'time_from','xtype':'datecolumn','format':'d.m.Y H:i','sortable':false,'width':110,'grouped':true},
         ...
       ],
       'features':[{
         'ftype':'grouping',
         'groupHeaderTpl':'{[headerSet(values)]}',
         'enableGroupingMenu':false 
       }],
       'plugins':[...],
       'listeners':{...}
     });
    
    var headerSet = function(values){
      if(values.name instanceof Date) return Ext.util.Format.date(values.name,'d F l');
      else return values.name;
    }
    System: OpenSuse 12.2, FireFox 17.0

  2. #2
    Sencha - Ext JS Dev Team Animal's Avatar
    Join Date
    Mar 2007
    Location
    Notts/Redwood City
    Posts
    30,508
    Vote Rating
    58
    Animal has a spectacular aura about Animal has a spectacular aura about Animal has a spectacular aura about

      0  

    Default


    Could it be that your browser is using a cached CSS file?

  3. #3
    Sencha Premium Member aiky.cc's Avatar
    Join Date
    Aug 2012
    Location
    Novosibirsk, Russia
    Posts
    26
    Vote Rating
    0
    aiky.cc is on a distinguished road

      0  

    Default


    I just tested again with clearing cache and was same result.

  4. #4
    Sencha - Ext JS Dev Team Animal's Avatar
    Join Date
    Mar 2007
    Location
    Notts/Redwood City
    Posts
    30,508
    Vote Rating
    58
    Animal has a spectacular aura about Animal has a spectacular aura about Animal has a spectacular aura about

      0  

    Default


    Those two screenshots.

    The diff is the underlining of group headers?

  5. #5
    Sencha - Ext JS Dev Team Animal's Avatar
    Join Date
    Mar 2007
    Location
    Notts/Redwood City
    Posts
    30,508
    Vote Rating
    58
    Animal has a spectacular aura about Animal has a spectacular aura about Animal has a spectacular aura about

      0  

    Default


    THere is a known problem (just fixed in code here) with grouping by date.

    That double spinner in the LoadMask. How did you get that to appear? The load mask always looks normal for me.

  6. #6
    Sencha Premium Member aiky.cc's Avatar
    Join Date
    Aug 2012
    Location
    Novosibirsk, Russia
    Posts
    26
    Vote Rating
    0
    aiky.cc is on a distinguished road

      0  

    Default


    oops.. loading and underlining solved by replacing ext-all.css from 4.1 to 4.2.0

    But still grouping not working.
    Quote Originally Posted by Animal View Post
    THere is a known problem (just fixed in code here) with grouping by date.
    OK

Thread Participants: 1