[CLOSED] GridPanel with BufferedRenderer Bug

Page 1 of 2 12 LastLast
  1. #1

    [CLOSED] GridPanel with BufferedRenderer Bug

    I have a GridPanel with the BufferedRenderer plugin. Its Store is loaded with JSON data from a web service and there are filters that can be applied that will reload the Store according to what is selected. For example, if the grid displays a list of movies with columns movie name, director name, and producer name, you can filter by director name and it will reload only movies with that director.

    The bug I'm experiencing is if you scroll far enough down the GridPanel, and then select a filter such that the reloaded results do not span as far down as you scrolled, when you scroll back up the GridPanel is blank and it stays that way unless I reload the page. I'm hoping there is a simple setting I'm missing that will just fix this...

    I create the GridPanel in code behind:
    Ext.Net.GridPanel mainTable = new Ext.Net.GridPanel()
    {
        ID = "MainTable",
        Title = mainTableTitle,
        MultiSelect = true,
        Plugins = {
            new Ext.Net.BufferedRenderer(){
                ID = "MainTable_BufferedRenderer"
            }
        },
        Store = { GetStore() },
        SelectionModel = {
            new Ext.Net.CellSelectionModel(){ }
        }
    };
    The method GetStore creates the Store that loads the GridPanel:
    private Ext.Net.Store GetStore(bool autoLoad = true)
    {
        string proxyUrl = dataUrl + "/" + webServiceMethod;
    
        Ext.Net.Model storeModel = new Ext.Net.Model();
        foreach (GridColumns item in this.mainTableColumns)
        {
            storeModel.Fields.Add(new Ext.Net.ModelField(item.GetColumnName(), item.GetColumnType()));
        }
    
        Ext.Net.Store resultStore = new Ext.Net.Store()
        {
            AutoLoad = autoLoad,
            Proxy =
            {
                new Ext.Net.AjaxProxy()
                {
                    Json = true,
                    ActionMethods = { Read = Ext.Net.HttpMethod.POST, Create = Ext.Net.HttpMethod.POST },
                    Url = proxyUrl,
                    Headers = {
                        new Ext.Net.Parameter("Accept", "application/json"),
                        new Ext.Net.Parameter("Content-Type", "application/json")
                    },
                    Reader = { new Ext.Net.JsonReader() { Root = "" } },
                    Writer = { new Ext.Net.JsonWriter() { Root = "", Encode = true } }
                }
            }
        };
        resultStore.Model.Add(storeModel);
    
        return resultStore;
    }
    And then in javascript here is what is executed when a filter is applied to refresh the grid:
    function ApplyFilter(sender, excludeGrid) {
        if (sender === '') {
            var filters = App.FilterList.value;
            var filterArray = filters.split(",");
    
            //get json for filters
            var jsonString = "";
            for (i = 0; i < filterArray.length; i++) {
                if (excludeGrid !== (filterArray[i] + "_Grid") && filterArray[i] !== "MainTable") {
                    var grid = Ext.getCmp(filterArray[i] + "_Grid");
                    var gridJson = grid.getRowsValues({ selectedOnly: true });
                    gridJson = JSON.stringify(gridJson);
    
                    if (gridJson != "[]") {
                        if (jsonString === "") {
                            jsonString = gridJson;
    
                        }
                        else {
                            jsonString = jsonString + "," + gridJson;
                        }
                    }
                }
            }
            jsonString = "{ \"data\": [" + jsonString + "] }";
    
            //reload grid
            for (j = 0; j < filterArray.length; j++) {
                var gridReload;
                if (filterArray[j] === "MainTable") {
                    gridReload = Ext.getCmp("MainTable");
                    if (typeof exclude === "undefined") {
                        ExecuteFilter(gridReload, jsonString, excludeGrid);
                    }
                    else {
                        ExecuteFilter(gridReload, jsonString);
                    }
                }
            }
        }
    }
    
    function ExecuteFilter(grid, jsonString, excludeGrid) {
        if (grid.getId() === "MainTable") {
            grid.getStore().reload({ params: { json: jsonString} });
        }
    }
    Last edited by Daniil; Aug 26, 2013 at 5:36 AM. Reason: [CLOSED]
  2. #2
    Hi @elisa,

    What about to scroll the GridPanel to the top before applying a filter?

    We would be happy to investigate the issue in detail if you can provide a full runnable test case.
  3. #3
    It's not a problem if I scroll all the way to the top before applying the filter. Below is a sample of JSON data we would load the grid with. A case that would generate that bug for me is if I scroll all the way down and then filter by "COUNTRY_NAME":"Brazil"

    [
    {"CITY":"Buenos Aires","STATE":" ","COUNTRYNAME":"Argentina"},
    {"CITY":"Melbourne","STATE":" ","COUNTRYNAME":"Australia"},
    {"CITY":"Sydney","STATE":" ","COUNTRYNAME":"Australia"},
    {"CITY":"Vienna","STATE":" ","COUNTRYNAME":"Austria"},
    {"CITY":"Nassau","STATE":" ","COUNTRYNAME":"Bahamas"},
    {"CITY":"Brussels","STATE":" ","COUNTRYNAME":"Belgium"},
    {"CITY":"Belo Horizonte","STATE":" ","COUNTRYNAME":"Brazil"},
    {"CITY":"Curitiba","STATE":" ","COUNTRYNAME":"Brazil"},
    {"CITY":"Porto Alegre","STATE":" ","COUNTRYNAME":"Brazil"},
    {"CITY":"Recife","STATE":" ","COUNTRYNAME":"Brazil"},
    {"CITY":"Rio De Janeiro","STATE":" ","COUNTRYNAME":"Brazil"},
    {"CITY":"Rio De Janeiro","STATE":" ","COUNTRYNAME":"Brazil"},
    {"CITY":"Sao Paulo","STATE":" ","COUNTRYNAME":"Brazil"},
    {"CITY":"Sao Paulo","STATE":" ","COUNTRYNAME":"Brazil"},
    {"CITY":"Sao Paulo","STATE":" ","COUNTRYNAME":"Brazil"},
    {"CITY":"Vancouver","STATE":"BC","COUNTRYNAME":"Ca nada"},
    {"CITY":"Toronto","STATE":"ON","COUNTRYNAME":"Cana da"},
    {"CITY":"Santiago","STATE":" ","COUNTRYNAME":"Chile"},
    {"CITY":"Beijing","STATE":" ","COUNTRYNAME":"China"},
    {"CITY":"Shanghai","STATE":" ","COUNTRYNAME":"China"},
    {"CITY":"Bogota","STATE":" ","COUNTRYNAME":"Colombia"},
    {"CITY":"Copenhagen","STATE":" ","COUNTRYNAME":"Denmark"},
    {"CITY":"Paris","STATE":" ","COUNTRYNAME":"France"},
    {"CITY":"Paris","STATE":" ","COUNTRYNAME":"France"},
    {"CITY":"Frankfurt","STATE":" ","COUNTRYNAME":"Germany"},
    {"CITY":"Athens","STATE":" ","COUNTRYNAME":"Greece"},
    {"CITY":"Hong Kong","STATE":" ","COUNTRYNAME":"Hong Kong"},
    {"CITY":"Hong Kong","STATE":" ","COUNTRYNAME":"Hong Kong"},
    {"CITY":"Hong Kong","STATE":" ","COUNTRYNAME":"Hong Kong"},
    {"CITY":"Hong Kong","STATE":" ","COUNTRYNAME":"Hong Kong"},
    {"CITY":"Hong Kong","STATE":" ","COUNTRYNAME":"Hong Kong"},
    {"CITY":"Hong Kong","STATE":" ","COUNTRYNAME":"Hong Kong"},
    {"CITY":"Ahmedabad","STATE":" ","COUNTRYNAME":"India"},
    {"CITY":"Bangalore","STATE":" ","COUNTRYNAME":"India"},
    {"CITY":"Bangalore","STATE":" ","COUNTRYNAME":"India"},
    {"CITY":"Chennai","STATE":" ","COUNTRYNAME":"India"},
    {"CITY":"Hyderabad","STATE":" ","COUNTRYNAME":"India"},
    {"CITY":"Kolkata","STATE":" ","COUNTRYNAME":"India"},
    {"CITY":"Mumbai","STATE":" ","COUNTRYNAME":"India"},
    {"CITY":"Mumbai","STATE":" ","COUNTRYNAME":"India"},
    {"CITY":"Mumbai","STATE":" ","COUNTRYNAME":"India"},
    {"CITY":"Mumbai","STATE":" ","COUNTRYNAME":"India"},
    {"CITY":"Mumbai","STATE":" ","COUNTRYNAME":"India"},
    {"CITY":"Mumbai","STATE":" ","COUNTRYNAME":"India"},
    {"CITY":"Mumbai","STATE":" ","COUNTRYNAME":"India"},
    {"CITY":"New Delhi","STATE":" ","COUNTRYNAME":"India"},
    {"CITY":"Pune","STATE":" ","COUNTRYNAME":"India"},
    {"CITY":"Dublin","STATE":" ","COUNTRYNAME":"Ireland"},
    {"CITY":"Milan","STATE":" ","COUNTRYNAME":"Italy"},
    {"CITY":"Milan","STATE":" ","COUNTRYNAME":"Italy"},
    {"CITY":"Fukuoka","STATE":" ","COUNTRYNAME":"Japan"},
    {"CITY":"Nagoya","STATE":" ","COUNTRYNAME":"Japan"},
    {"CITY":"Osaka","STATE":" ","COUNTRYNAME":"Japan"},
    {"CITY":"Tokyo","STATE":" ","COUNTRYNAME":"Japan"},
    {"CITY":"Senningerberg","STATE":" ","COUNTRYNAME":"Luxembourg"},
    {"CITY":"Mexico City","STATE":" ","COUNTRYNAME":"Mexico"},
    {"CITY":"Monterrey","STATE":" ","COUNTRYNAME":"Mexico"},
    {"CITY":"Amsterdam","STATE":" ","COUNTRYNAME":"Netherlands"},
    {"CITY":"Lima","STATE":" ","COUNTRYNAME":"Peru"},
    {"CITY":"Doha","STATE":" ","COUNTRYNAME":"Qatar"},
    {"CITY":"Riyadh","STATE":" ","COUNTRYNAME":"Saudi Arabia"},
    {"CITY":"Singapore","STATE":" ","COUNTRYNAME":"Singapore"},
    {"CITY":"Cape Town","STATE":" ","COUNTRYNAME":"South Africa"},
    {"CITY":"Seoul","STATE":" ","COUNTRYNAME":"South Korea"},
    {"CITY":"Madrid","STATE":" ","COUNTRYNAME":"Spain"},
    {"CITY":"Stockholm","STATE":" ","COUNTRYNAME":"Sweden"},
    {"CITY":"Geneva","STATE":" ","COUNTRYNAME":"Switzerland"},
    {"CITY":"Geneva","STATE":" ","COUNTRYNAME":"Switzerland"},
    {"CITY":"Geneva","STATE":" ","COUNTRYNAME":"Switzerland"},
    {"CITY":"Zurich","STATE":" ","COUNTRYNAME":"Switzerland"},
    {"CITY":"Kaohsiung","STATE":" ","COUNTRYNAME":"Taiwan"},
    {"CITY":"Panchiao","STATE":" ","COUNTRYNAME":"Taiwan"},
    {"CITY":"TaiChung","STATE":" ","COUNTRYNAME":"Taiwan"},
    {"CITY":"Tainan City","STATE":" ","COUNTRYNAME":"Taiwan"},
    {"CITY":"Taipei","STATE":" ","COUNTRYNAME":"Taiwan"},
    {"CITY":"Taoyuan","STATE":" ","COUNTRYNAME":"Taiwan"},
    {"CITY":"Istanbul","STATE":" ","COUNTRYNAME":"Turkey"},
    {"CITY":"Dubai","STATE":" ","COUNTRYNAME":"United Arab Emirates"},
    {"CITY":"Bournemouth","STATE":" ","COUNTRYNAME":"United Kingdom"},
    {"CITY":"Edinburgh","STATE":" ","COUNTRYNAME":"United Kingdom"},
    {"CITY":"Glasgow","STATE":" ","COUNTRYNAME":"United Kingdom"},
    {"CITY":"Liverpool","STATE":" ","COUNTRYNAME":"United Kingdom"},
    {"CITY":"London","STATE":" ","COUNTRYNAME":"United Kingdom"},
    {"CITY":"London","STATE":" ","COUNTRYNAME":"United Kingdom"},
    {"CITY":"London","STATE":" ","COUNTRYNAME":"United Kingdom"},
    {"CITY":"London","STATE":" ","COUNTRYNAME":"United Kingdom"},
    {"CITY":"London","STATE":" ","COUNTRYNAME":"United Kingdom"},
    {"CITY":"London","STATE":" ","COUNTRYNAME":"United Kingdom"},
    {"CITY":"London","STATE":" ","COUNTRYNAME":"United Kingdom"},
    {"CITY":"London","STATE":" ","COUNTRYNAME":"United Kingdom"},
    {"CITY":"London","STATE":" ","COUNTRYNAME":"United Kingdom"},
    {"CITY":"Phoenix","STATE":"AZ","COUNTRYNAME":"Unit ed States"},
    {"CITY":"Scottsdale","STATE":"AZ","COUNTRYNAME":"U nited States"},
    {"CITY":"Tucson","STATE":"AZ","COUNTRYNAME":"Unite d States"},
    {"CITY":"Work At Home","STATE":"AZ","COUNTRYNAME":"United States"},
    {"CITY":"Irvine","STATE":"CA","COUNTRYNAME":"Unite d States"},
    {"CITY":"Irvine","STATE":"CA","COUNTRYNAME":"Unite d States"},
    {"CITY":"La Canada","STATE":"CA","COUNTRYNAME":"United States"},
    {"CITY":"Los Angeles","STATE":"CA","COUNTRYNAME":"United States"},
    {"CITY":"Los Angeles","STATE":"CA","COUNTRYNAME":"United States"},
    {"CITY":"Newport Beach","STATE":"CA","COUNTRYNAME":"United States"},
    {"CITY":"Palo Alto","STATE":"CA","COUNTRYNAME":"United States"},
    {"CITY":"San Francisco","STATE":"CA","COUNTRYNAME":"United States"},
    {"CITY":"Santa Barbara","STATE":"CA","COUNTRYNAME":"United States"},
    {"CITY":"Work At Home","STATE":"CA","COUNTRYNAME":"United States"},
    {"CITY":"Denver","STATE":"CO","COUNTRYNAME":"Unite d States"},
    {"CITY":"Englewood","STATE":"CO","COUNTRYNAME":"Un ited States"},
    {"CITY":"Work At Home","STATE":"CO","COUNTRYNAME":"United States"},
    {"CITY":"Greenwich","STATE":"CT","COUNTRYNAME":"Un ited States"},
    {"CITY":"Work At Home","STATE":"CT","COUNTRYNAME":"United States"},
    {"CITY":"Washington","STATE":"DC","COUNTRYNAME":"U nited States"},
    {"CITY":"Washington","STATE":"DC","COUNTRYNAME":"U nited States"},
    {"CITY":"Washington","STATE":"DC","COUNTRYNAME":"U nited States"},
    {"CITY":"Newark","STATE":"DE","COUNTRYNAME":"Unite d States"},
    {"CITY":"Newark","STATE":"DE","COUNTRYNAME":"Unite d States"},
    {"CITY":"Newark","STATE":"DE","COUNTRYNAME":"Unite d States"},
    {"CITY":"Newark","STATE":"DE","COUNTRYNAME":"Unite d States"},
    {"CITY":"Newark","STATE":"DE","COUNTRYNAME":"Unite d States"},
    {"CITY":"Newark","STATE":"DE","COUNTRYNAME":"Unite d States"},
    {"CITY":"Newark","STATE":"DE","COUNTRYNAME":"Unite d States"},
    {"CITY":"Boca Raton","STATE":"FL","COUNTRYNAME":"United States"},
    {"CITY":"Jacksonville","STATE":"FL","COUNTRYNAME": "United States"},
    {"CITY":"Jacksonville","STATE":"FL","COUNTRYNAME": "United States"},
    {"CITY":"Miami","STATE":"FL","COUNTRYNAME":"Uni ted States"},
    {"CITY":"Naples","STATE":"FL","COUNTRYNAME":"Unite d States"},
    {"CITY":"Palm Beach","STATE":"FL","COUNTRYNAME":"United States"},
    {"CITY":"Palm Beach Gardens","STATE":"FL","COUNTRYNAME":"United States"},
    {"CITY":"Tampa","STATE":"FL","COUNTRYNAME":"Uni ted States"},
    {"CITY":"Tampa","STATE":"FL","COUNTRYNAME":"Uni ted States"},
    {"CITY":"Tampa","STATE":"FL","COUNTRYNAME":"Uni ted States"},
    {"CITY":"Work At Home","STATE":"FL","COUNTRYNAME":"United States"},
    {"CITY":"Atlanta","STATE":"GA","COUNTRYNAME":"Unit ed States"},
    {"CITY":"Atlanta","STATE":"GA","COUNTRYNAME":"Unit ed States"},
    {"CITY":"Atlanta","STATE":"GA","COUNTRYNAME":"Unit ed States"},
    {"CITY":"Work At Home","STATE":"GA","COUNTRYNAME":"United States"},
    {"CITY":"Work At Home","STATE":"IA","COUNTRYNAME":"United States"},
    {"CITY":"Bloomingdale","STATE":"IL","COUNTRYNAME": "United States"},
    {"CITY":"Chicago","STATE":"IL","COUNTRYNAME":"Unit ed States"},
    {"CITY":"Chicago","STATE":"IL","COUNTRYNAME":"Unit ed States"},
    {"CITY":"Chicago","STATE":"IL","COUNTRYNAME":"Unit ed States"},
    {"CITY":"Naperville","STATE":"IL","COUNTRYNAME":"U nited States"},
    {"CITY":"Peoria","STATE":"IL","COUNTRYNAME":"Unite d States"},
    {"CITY":"Springfield","STATE":"IL","COUNTRYNAME":" United States"},
    {"CITY":"Westmont","STATE":"IL","COUNTRYNAME":"Uni ted States"},
    {"CITY":"Winnetka","STATE":"IL","COUNTRYNAME":"Uni ted States"},
    {"CITY":"Work At Home","STATE":"IL","COUNTRYNAME":"United States"},
    {"CITY":"Fort Wayne","STATE":"IN","COUNTRYNAME":"United States"},
    {"CITY":"Indianapolis","STATE":"IN","COUNTRYNAME": "United States"},
    {"CITY":"Work At Home","STATE":"IN","COUNTRYNAME":"United States"},
    {"CITY":"Overland Park","STATE":"KS","COUNTRYNAME":"United States"},
    {"CITY":"Work At Home","STATE":"KS","COUNTRYNAME":"United States"},
    {"CITY":"Lexington","STATE":"KY","COUNTRYNAME":"Un ited States"},
    {"CITY":"Louisville","STATE":"KY","COUNTRYNAME":"U nited States"},
    {"CITY":"Louisville","STATE":"KY","COUNTRYNAME":"U nited States"},
    {"CITY":"Work At Home","STATE":"KY","COUNTRYNAME":"United States"},
    {"CITY":"Baton Rouge","STATE":"LA","COUNTRYNAME":"United States"},
    {"CITY":"Houma","STATE":"LA","COUNTRYNAME":"Uni ted States"},
    {"CITY":"Lafayette","STATE":"LA","COUNTRYNAME":"Un ited States"},
    {"CITY":"Monroe","STATE":"LA","COUNTRYNAME":"Unite d States"},
    {"CITY":"New Orleans","STATE":"LA","COUNTRYNAME":"United States"},
    {"CITY":"Shreveport","STATE":"LA","COUNTRYNAME":"U nited States"},
    {"CITY":"Work At Home","STATE":"LA","COUNTRYNAME":"United States"},
    {"CITY":"Boston","STATE":"MA","COUNTRYNAME":"Unite d States"},
    {"CITY":"Boston","STATE":"MA","COUNTRYNAME":"Unite d States"},
    {"CITY":"Boston","STATE":"MA","COUNTRYNAME":"Unite d States"},
    {"CITY":"Work At Home","STATE":"MA","COUNTRYNAME":"United States"},
    {"CITY":"Hunt Valley","STATE":"MD","COUNTRYNAME":"United States"},
    {"CITY":"Work At Home","STATE":"MD","COUNTRYNAME":"United States"},
    {"CITY":"Ann Arbor","STATE":"MI","COUNTRYNAME":"United States"},
    {"CITY":"Bloomfield Hills","STATE":"MI","COUNTRYNAME":"United States"},
    {"CITY":"Grand Rapids","STATE":"MI","COUNTRYNAME":"United States"},
    {"CITY":"Grand Rapids","STATE":"MI","COUNTRYNAME":"United States"},
    {"CITY":"Grosse Pointe","STATE":"MI","COUNTRYNAME":"United States"},
    {"CITY":"Troy","STATE":"MI","COUNTRYNAME":"Unit ed States"},
    {"CITY":"Waterford","STATE":"MI","COUNTRYNAME":"Un ited States"},
    {"CITY":"Work At Home","STATE":"MI","COUNTRYNAME":"United States"},
    {"CITY":"Minneapolis","STATE":"MN","COUNTRYNAME":" United States"},
    {"CITY":"Work At Home","STATE":"MN","COUNTRYNAME":"United States"},
    {"CITY":"Chesterfield","STATE":"MO","COUNTRYNAME": "United States"},
    {"CITY":"Clayton","STATE":"MO","COUNTRYNAME":"Unit ed States"},
    {"CITY":"Clayton","STATE":"MO","COUNTRYNAME":"Unit ed States"},
    {"CITY":"Kansas City","STATE":"MO","COUNTRYNAME":"United States"},
    {"CITY":"Work At Home","STATE":"MO","COUNTRYNAME":"United States"},
    {"CITY":"Work At Home","STATE":"NC","COUNTRYNAME":"United States"},
    {"CITY":"Florham Park","STATE":"NJ","COUNTRYNAME":"United States"},
    {"CITY":"Jersey City","STATE":"NJ","COUNTRYNAME":"United States"},
    {"CITY":"Morristown","STATE":"NJ","COUNTRYNAME":"U nited States"},
    {"CITY":"Princeton","STATE":"NJ","COUNTRYNAME":"Un ited States"},
    {"CITY":"Whippany","STATE":"NJ","COUNTRYNAME":"Uni ted States"},
    {"CITY":"Work At Home","STATE":"NJ","COUNTRYNAME":"United States"},
    {"CITY":"Brooklyn","STATE":"NY","COUNTRYNAME":"Uni ted States"},
    {"CITY":"Brooklyn","STATE":"NY","COUNTRYNAME":"Uni ted States"},
    {"CITY":"Garden City","STATE":"NY","COUNTRYNAME":"United States"},
    {"CITY":"Melville","STATE":"NY","COUNTRYNAME":"Uni ted States"},
    {"CITY":"New Hyde Park","STATE":"NY","COUNTRYNAME":"United States"},
    {"CITY":"New York","STATE":"NY","COUNTRYNAME":"United States"},
    {"CITY":"New York","STATE":"NY","COUNTRYNAME":"United States"},
    {"CITY":"New York","STATE":"NY","COUNTRYNAME":"United States"},
    {"CITY":"New York","STATE":"NY","COUNTRYNAME":"United States"},
    {"CITY":"New York","STATE":"NY","COUNTRYNAME":"United States"},
    {"CITY":"New York","STATE":"NY","COUNTRYNAME":"United States"},
    {"CITY":"New York","STATE":"NY","COUNTRYNAME":"United States"},
    {"CITY":"New York","STATE":"NY","COUNTRYNAME":"United States"},
    {"CITY":"New York","STATE":"NY","COUNTRYNAME":"United States"},
    {"CITY":"New York","STATE":"NY","COUNTRYNAME":"United States"},
    {"CITY":"New York","STATE":"NY","COUNTRYNAME":"United States"},
    {"CITY":"New York","STATE":"NY","COUNTRYNAME":"United States"},
    {"CITY":"Rochester","STATE":"NY","COUNTRYNAME":"Un ited States"},
    {"CITY":"Staten Island","STATE":"NY","COUNTRYNAME":"United States"},
    {"CITY":"Syracuse","STATE":"NY","COUNTRYNAME":"Uni ted States"},
    {"CITY":"White Plains","STATE":"NY","COUNTRYNAME":"United States"},
    {"CITY":"Work At Home","STATE":"NY","COUNTRYNAME":"United States"},
    {"CITY":"Akron","STATE":"OH","COUNTRYNAME":"Uni ted States"},
    {"CITY":"Beachwood","STATE":"OH","COUNTRYNAME":"Un ited States"},
    {"CITY":"Cincinnati","STATE":"OH","COUNTRYNAME":"U nited States"},
    {"CITY":"Cleveland","STATE":"OH","COUNTRYNAME":"Un ited States"},
    {"CITY":"Columbus","STATE":"OH","COUNTRYNAME":"Uni ted States"},
    {"CITY":"Columbus","STATE":"OH","COUNTRYNAME":"Uni ted States"},
    {"CITY":"Columbus","STATE":"OH","COUNTRYNAME":"Uni ted States"},
    {"CITY":"Columbus","STATE":"OH","COUNTRYNAME":"Uni ted States"},
    {"CITY":"Columbus","STATE":"OH","COUNTRYNAME":"Uni ted States"},
    {"CITY":"Columbus","STATE":"OH","COUNTRYNAME":"Uni ted States"},
    {"CITY":"Dayton","STATE":"OH","COUNTRYNAME":"Unite d States"},
    {"CITY":"Hudson","STATE":"OH","COUNTRYNAME":"Unite d States"},
    {"CITY":"Lima","STATE":"OH","COUNTRYNAME":"Unit ed States"},
    {"CITY":"Westerville","STATE":"OH","COUNTRYNAME":" United States"},
    {"CITY":"Work At Home","STATE":"OH","COUNTRYNAME":"United States"},
    {"CITY":"Oklahoma City","STATE":"OK","COUNTRYNAME":"United States"},
    {"CITY":"Tulsa","STATE":"OK","COUNTRYNAME":"Uni ted States"},
    {"CITY":"Work At Home","STATE":"OR","COUNTRYNAME":"United States"},
    {"CITY":"Blue Bell","STATE":"PA","COUNTRYNAME":"United States"},
    {"CITY":"Philadelphia","STATE":"PA","COUNTRYNAME": "United States"},
    {"CITY":"Philadelphia","STATE":"PA","COUNTRYNAME": "United States"},
    {"CITY":"Pittsburgh","STATE":"PA","COUNTRYNAME":"U nited States"},
    {"CITY":"Work At Home","STATE":"PA","COUNTRYNAME":"United States"},
    {"CITY":"Providence","STATE":"RI","COUNTRYNAME":"U nited States"},
    {"CITY":"Work At Home","STATE":"SC","COUNTRYNAME":"United States"},
    {"CITY":"Nashville","STATE":"TN","COUNTRYNAME":"Un ited States"},
    {"CITY":"Work At Home","STATE":"TN","COUNTRYNAME":"United States"},
    {"CITY":"Arlington","STATE":"TX","COUNTRYNAME":"Un ited States"},
    {"CITY":"Arlington","STATE":"TX","COUNTRYNAME":"Un ited States"},
    {"CITY":"Austin","STATE":"TX","COUNTRYNAME":"Unite d States"},
    {"CITY":"Dallas","STATE":"TX","COUNTRYNAME":"Unite d States"},
    {"CITY":"Dallas","STATE":"TX","COUNTRYNAME":"Unite d States"},
    {"CITY":"Dallas","STATE":"TX","COUNTRYNAME":"Unite d States"},
    {"CITY":"Fort Worth","STATE":"TX","COUNTRYNAME":"United States"},
    {"CITY":"Frisco","STATE":"TX","COUNTRYNAME":"Unite d States"},
    {"CITY":"Houston","STATE":"TX","COUNTRYNAME":"Unit ed States"},
    {"CITY":"Houston","STATE":"TX","COUNTRYNAME":"Unit ed States"},
    {"CITY":"Lakeway","STATE":"TX","COUNTRYNAME":"Unit ed States"},
    {"CITY":"Lewisville","STATE":"TX","COUNTRYNAME":"U nited States"},
    {"CITY":"San Antonio","STATE":"TX","COUNTRYNAME":"United States"},
    {"CITY":"Work At Home","STATE":"TX","COUNTRYNAME":"United States"},
    {"CITY":"Virginia Beach","STATE":"VA","COUNTRYNAME":"United States"},
    {"CITY":"Work At Home","STATE":"VA","COUNTRYNAME":"United States"},
    {"CITY":"Bellevue","STATE":"WA","COUNTRYNAME":"Uni ted States"},
    {"CITY":"Seattle","STATE":"WA","COUNTRYNAME":"Unit ed States"},
    {"CITY":"Seattle","STATE":"WA","COUNTRYNAME":"Unit ed States"},
    {"CITY":"Work At Home","STATE":"WA","COUNTRYNAME":"United States"},
    {"CITY":"Appleton","STATE":"WI","COUNTRYNAME":"Uni ted States"},
    {"CITY":"Green Bay","STATE":"WI","COUNTRYNAME":"United States"},
    {"CITY":"Janesville","STATE":"WI","COUNTRYNAME":"U nited States"},
    {"CITY":"Mequon","STATE":"WI","COUNTRYNAME":"Unite d States"},
    {"CITY":"Milwaukee","STATE":"WI","COUNTRYNAME":"Un ited States"},
    {"CITY":"Work At Home","STATE":"WI","COUNTRYNAME":"United States"},
    {"CITY":"Charleston","STATE":"WV","COUNTRYNAME":"U nited States"},
    {"CITY":"Huntington","STATE":"WV","COUNTRYNAME":"U nited States"},
    {"CITY":"Wheeling","STATE":"WV","COUNTRYNAME":"Uni ted States"},
    {"CITY":"Caracas","STATE":" ","COUNTRYNAME":"Venezuela"}
    ]
    Last edited by elisa; Aug 22, 2013 at 5:54 PM.
  4. #4
    Quote Originally Posted by elisa View Post
    It's not a problem if I scroll all the way to the top before applying the filter.
    Yes, it is my suggestion to resolve the problem - programmatically scroll the GridPanel to the top before applying a filter.

    Quote Originally Posted by elisa View Post
    Below is a sample of JSON data we would load the grid with. A case that would generate that bug for me is if I scroll all the way down and then filter by "COUNTRY_NAME":"Brazil"
    I rather meant a full standalone ASPX page and a WebService or whatever with the test data.
  5. #5
    Thanks Daniil. I'm using
    grid.getView().focusRow(rowIdx);
    What I quickly realized is the row index of the first record is only 0 the first time a filter is applied. Then the index of the first record returned by the store is not 0. How do I get this index?
  6. #6
    Please demonstrate how you are getting records and its indexes.

    Do you use a record's index property? If so, do not rely on that property. It is not maintained always.
  7. #7
    That is exactly my question. I was just using
    grid.getView().focusRow(0);
    What is the correct way of getting the row index for the top record?
  8. #8
    I also tried this:
    grid.getView().scrollToTop();
    But again it only works for the first filter.
  9. #9
    Try to use scrollTo method of BufferedRenderer plugin
    http://docs-origin.sencha.com/extjs/...ethod-scrollTo
    Vladimir Shcheglov
    Sr. Developer
  10. #10
    Also please note that filtering should be performed in callback of scrollTo method
    Vladimir Shcheglov
    Sr. Developer
Page 1 of 2 12 LastLast

Similar Threads

  1. Replies: 7
    Last Post: Jun 26, 2015, 9:04 AM
  2. [CLOSED] bufferedrenderer in version 2.1
    By JCarlosF in forum 2.x Premium Help
    Replies: 1
    Last Post: Aug 13, 2013, 4:45 PM

Tags for this Thread

Posting Permissions