Thank you for reporting this bug. We will make it our priority to review this report.
  1. #1
    Ext User
    Join Date
    May 2009
    Location
    Italy
    Posts
    116
    Vote Rating
    0
    robertoroberto is on a distinguished road

      0  

    Default [CLOSED][DUP][3.0.0]PagingToolbar not showing empty message when store is empty

    [CLOSED][DUP][3.0.0]PagingToolbar not showing empty message when store is empty


    I'm using the Ext.PagingToolbar with cfg param "emptyMsg" (in every case it have a default message), but also if my store is empty, the emptyMsg is not diplayed.

    The emptyMsg is set from the updateInfo function (it is declared as private).
    Code:
        updateInfo : function(){
            if(this.displayItem){
                var count = this.store.getCount();
                var msg = count == 0 ?
                    this.emptyMsg :
                    String.format(
                        this.displayMsg,
                        this.cursor+1, this.cursor+count, this.store.getTotalCount()
                    );
                this.displayItem.setText(msg);
            }
        },
    Unfortunatelly the updateInfo function is called from the onLoad function but onLoad is not called if store is empty
    Code:
        bindStore : function(store, initial){
            var doLoad;
            if(!initial && this.store){
                this.store.un('beforeload', this.beforeLoad, this);
                this.store.un('load', this.onLoad, this);
                this.store.un('exception', this.onLoadError, this);
                if(store !== this.store && this.store.autoDestroy){
                    this.store.destroy();
                }
            }
            if(store){
                store = Ext.StoreMgr.lookup(store);
                store.on({
                    scope: this,
                    beforeload: this.beforeLoad,
                    load: this.onLoad,
                    exception: this.onLoadError
                });
               doLoad = store.getCount() > 0;
            }
            this.store = store;
           if(doLoad){
               this.onLoad(store, null, {});
            }
        },
    Only of store count is > 0 the onLoad is called... so the empty message seems never used.

    I believe this is a bug.

    thanks

  2. #2
    Sencha - Ext JS Dev Team evant's Avatar
    Join Date
    Apr 2007
    Location
    Sydney, Australia
    Posts
    16,989
    Vote Rating
    649
    evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute

      0  

    Default


    Thanks for the report, but it's already been fixed in SVN, please do a search before posting.

    Marking this as closed.
    Evan Trimboli
    Sencha Developer
    Twitter - @evantrimboli
    Don't be afraid of the source code!

  3. #3
    Ext User
    Join Date
    May 2009
    Location
    Italy
    Posts
    116
    Vote Rating
    0
    robertoroberto is on a distinguished road

      0  

    Default


    Ty and sorry
    I try to looking for open issue, but I found only http://extjs.com/forum/showthread.php?t=21167

    I believe that it is not easy looking for bug issue in a forum.
    Have ExtJS think to use an alternative way for bug reporting ? (at least only for bugs.. not for help)

    Probably something more structured can help us to found issue
    E.g. having a category / component and so on...
    Have you never see JIRA (http://www.atlassian.com/software/jira/) : JIRA is free for any Open Source project to use.

  4. #4
    Sencha - Ext JS Dev Team evant's Avatar
    Join Date
    Apr 2007
    Location
    Sydney, Australia
    Posts
    16,989
    Vote Rating
    649
    evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute evant has a reputation beyond repute

      0  

    Default


    We do use a tracking tool internally. At this point I don't think we're going to make it public.
    Evan Trimboli
    Sencha Developer
    Twitter - @evantrimboli
    Don't be afraid of the source code!

Thread Participants: 1