Results 1 to 7 of 7

Thread: sorting bug extending GridPanel in 3.3.0

  1. #1
    Sencha User
    Join Date
    Jul 2007
    Location
    Hungary
    Posts
    58

    Default sorting bug extending GridPanel in 3.3.0

    Hi there,

    I extended the gridPanel components as the following:

    Code:
    InterPont.Hitel.UgynokLejelentoGrid = function( config )
    {
        InterPont.Hitel.UgynokLejelentoGrid.superclass.constructor.call(this,config);
    }
    
    Ext.extend( InterPont.Hitel.UgynokLejelentoGrid, Ext.grid.GridPanel, {
        initComponent: function()
        {
            var ds = new Ext.data.JsonStore({
                url: 'return JSON string'
                ,storeId: 'stUgynokok'
                ,root: 'ugynokok'
                ,fields: [
                    {name: 'ID', type: 'string'}
                   ,{name: 'Nev', type: 'string'}
                   ,{name: 'Iroda', type: 'string'}
                ]
            });
    //        var sm = new InterPont.ux.CtrlCheckboxSelectionModel();
            var sm = new Ext.grid.RowSelectionModel({singleselect:false});
            var columns = [
    //                sm,
                      {header: 'gynk neve', dataIndex: 'Nev', sortable: true, resizable: true}
                      ,{header: 'Iroda', dataIndex: 'Iroda', sortable: true}
                  ];
            Ext.apply( this, {
                store: ds
    //            ,cm: new Ext.grid.ColumnModel( columns )
                ,columns: columns
    //            ,sm: sm
            });
            
            InterPont.Hitel.UgynokLejelentoGrid.superclass.initComponent.apply(this,arguments);
        }
    });
    using it the following way:

    Code:
    var grid = new InterPont.Hitel.UgynokLejelentoGrid({
                id: 'gridUgynokLejelento',
                bbar: [intezetek,{
                    text: 'Sz?rs'
                    ,handler: this.filterByIntezetek
                },'->',{
                    text: 'Generl'
                    ,handler: this.generateExcel
                    ,scope:this
                },'|',{
                    text: 'PSZAF formtum'
                    ,handler: this.generatePSZAF
                    ,scope:this
                }]
            });
    
    
            Ext.StoreMgr.get('stUgynokok').load();
    Whatever I change or do the sorting doesn't work anymore. This is the simplest example I could cut off the code.
    Does anybody know where to look further?

    This code worked well in 3.2.x

    r. Sandor
    Last edited by carstep; 14 Oct 2010 at 1:39 AM. Reason: addition

  2. #2
    Sencha User
    Join Date
    Jul 2007
    Location
    Hungary
    Posts
    58

    Default

    I could find out that this only happens when the grid is in a Window ( or at least in an extended window )

    r. Sandor

  3. #3
    Sencha User
    Join Date
    Jul 2007
    Location
    Hungary
    Posts
    58

    Default

    further info I came across is, when I delete the cookies the functionality becomes active again until I refresh the site!

    r. Sandor

  4. #4
    Sencha User
    Join Date
    Jul 2007
    Location
    Hungary
    Posts
    58

    Default

    disabling statefullness on the Window object didn't solved the problem instead disabling it in the Grid did.

    r. Sandor

  5. #5
    Sencha User
    Join Date
    Aug 2009
    Posts
    480

    Default

    You should post in bugs if you think this is one.

    By the way,


    Code:
     
    //This part of code is useless since you are not doing anything else than calling the parent constructor...
    InterPont.Hitel.UgynokLejelentoGrid = function( config ) {
        InterPont.Hitel.UgynokLejelentoGrid.superclass.constructor.call(this,config);
    }
     
    //Should be
    InterPont.Hitel.UgynokLejelentoGrid = Ext.extend(Ext.grid.GridPanel, {
       ....
       /*If you really need to override the constructor, you can do it here*/,
       constructor: function(config) {
            //Do some stuff
           InterPont.Hitel.UgynokLejelentoGrid.superclass.constructor.call(this, config);
       }
    });

  6. #6
    Sencha User
    Join Date
    Jul 2007
    Location
    Hungary
    Posts
    58

    Default

    thanks for the info scarsick, is there any inforamation about this? I couldn't find any hints in the 2.x to 3.x migration guide

    r. Sandor

  7. #7
    Sencha User
    Join Date
    Aug 2009
    Posts
    480

    Default

    Post a test case in bugs if you think it's one...

Similar Threads

  1. extending GridPanel
    By Maharshi in forum Ext 2.x: Help & Discussion
    Replies: 2
    Last Post: 28 Apr 2009, 12:15 AM
  2. extending gridpanel
    By fxmisticat in forum Ext 2.x: Help & Discussion
    Replies: 18
    Last Post: 27 Jan 2009, 6:56 AM
  3. Extending GridPanel
    By lorenjerickson in forum Ext 2.x: Help & Discussion
    Replies: 0
    Last Post: 22 Jan 2008, 2:21 PM
  4. Ext1.0alpha1: bug or no bug in grid sorting?
    By Belgabor in forum Ext 2.x: Help & Discussion
    Replies: 1
    Last Post: 19 Feb 2007, 9:04 AM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •