1. #1
    Sencha User
    Join Date
    Feb 2012
    Location
    Katzenellenbogen
    Posts
    51
    Vote Rating
    1
    Moinsen is on a distinguished road

      0  

    Question buffered grid - buffered store in Ext 4.1b2

    buffered grid - buffered store in Ext 4.1b2


    Hi,

    i have a buffered grid which works perfect in Ext Js 3.4 and 4.07. The data is fetched during scrolling in 100 blocks and displayed in the grid. In 4.1b2 it stops after the first block and hangs. The second data block is ok as i can see in Firebug. I read about this issue here in the Forum before.

    Please let me know if there is a fix or a workaround for this. Maybe the API changed?

    Thanks!

  2. #2
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    37,525
    Vote Rating
    871
    mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute

      0  

    Default


    I'm unsure about your issue. Launching the example for the buffered grid, it is working just fine.
    Mitchell Simoens @SenchaMitch
    Sencha Inc, Senior Forum Manager
    ________________
    Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
    https://github.com/mitchellsimoens

    Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/

    Need more help with your app? Hire Sencha Services services@sencha.com

    Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is in print!

    When posting code, please use BBCode's CODE tags.

  3. #3
    Sencha User
    Join Date
    Feb 2012
    Location
    Katzenellenbogen
    Posts
    51
    Vote Rating
    1
    Moinsen is on a distinguished road

      0  

    Default


    In the buffered grid example you are working with: store.cacheRecords(records);
    Our 'buffered grid' is working with a own proxy. It looks like this:

    Ext.define('MyProxy', {
    extend: 'Ext.data.AjaxProxy',
    constructor: function(config) {
    MyProxy.superclass.constructor.call(this, config);
    this.initConfig(config);
    logInfo("MyProxy.constructor()");
    },
    doRequest: function(operation, callback, scope) {
    logInfo("MyProxy.doRequest() starts");

    pageRequest(operation, callback, scope);
    logInfo("MyProxy.doRequest() ends");
    return;
    }
    });

    So doRequest is triggered by verticalScrollerType: 'paginggridscroller' from the grid. If you scroll down at a certain point a new doRequest is triggered and the next 100 records are added to the grid. pageRequest is controlled by operation.page and operation.limit and delivers the next records with a database request.
    To start the whole thing its enough to say: bufferStore.guaranteeRange(0, count -1);

    Hope this makes it clear. Thank you!

  4. #4
    Sencha User
    Join Date
    Feb 2012
    Location
    Katzenellenbogen
    Posts
    51
    Vote Rating
    1
    Moinsen is on a distinguished road

      0  

    Question


    I tested it with 4.1b3. Now guaranteeRange even not starts the first doRequest on the proxy. So the behavior for buffered 'Reading' changes each build.

    Please let me know how to do buffered reading now. It cannot use cacheRecords because there are some ten thousand records to fetch. So i have to fetch them in handy blocks.


  5. #5
    Sencha - Ext JS Dev Team dongryphon's Avatar
    Join Date
    Jul 2009
    Location
    Kansas
    Posts
    1,403
    Vote Rating
    147
    dongryphon is a splendid one to behold dongryphon is a splendid one to behold dongryphon is a splendid one to behold dongryphon is a splendid one to behold dongryphon is a splendid one to behold dongryphon is a splendid one to behold dongryphon is a splendid one to behold

      0  

    Default


    The guaranteeRange method had been broken in 4.1 for sometime, but should be fixed in the next build (the fixes are already in the nightly build).

    See http://www.sencha.com/forum/showthre...rolling-in-4.1
    Don Griffin
    Engineering Manager - Frameworks (Ext JS / Sencha Touch)

    Check the docs. Learn how to (properly) report a framework issue and a Sencha Cmd issue

    "Use the source, Luke!"

Thread Participants: 2