1. #1
    Ext User
    Join Date
    Jun 2010
    Posts
    1
    Vote Rating
    0
    dc420563e5dd1c2f is on a distinguished road

      0  

    Exclamation Error When Reloading GroupingStore with JsonReader

    Error When Reloading GroupingStore with JsonReader


    All,
    I have an editor grid with its store set to the GroupingStore below, the grid/store load fine on initialisation, however subsequent calls using the reload method fail.

    My code is as per below:

    The GroupingStore:

    Code:
        STORE_data = new Ext.data.GroupingStore({
            storeId: 'STORE_data',
            groupField: 'pid',
            url: 'database.editorgrid.php',
            baseParams:{task: "LISTING", start: 0, limit: 100, handler: "table1"},
            sortInfo: {field: 'id', direction: 'ASC'},
            remoteSort: true,
            reader:new Ext.data.JsonReader({
                root: 'results',
                totalProperty: 'total',
                fields:    
                [
                    {
                        name: 'id',
                        type: 'int',
                        mapping: 'id'
                    },
                    {
                        name: 'pid',
                        type: 'int',
                        mapping: 'pid'
                    },
                    {
                        name: 'name',
                        type: 'string',
                        mapping: 'name'
                    }
                ]}
            )
        });
    Within the editorgrid, the view property has been set to:

    Code:
      view: new Ext.grid.GroupingView({enableGroupingMenu: true })
    What I need to do is to change the baseparams of the groupingstore (so it loads different underlying data), and inject this data into the grid.

    The code to do this works fine when using a JSONStore:

    Code:
     STORE_data.removeAll();
            STORE_data.baseParams = {task: "LISTING", start: 0, limit: 100, handler: 'table2'}; 
    STORE_data.reload();
    However, when the above lines are called with the GroupingStore, the error:

    Code:
    e is undefined
    Is given by firebug and no data is retrieved.

    Can anyone help? Any ideas? All feeback much appreciated!
    Last edited by dc420563e5dd1c2f; 23 Jul 2010 at 3:52 AM. Reason: Additional Clarification

Similar Threads

  1. Reloading Grid with JsonReader
    By akush2007 in forum Ext 2.x: Help & Discussion
    Replies: 3
    Last Post: 19 Jun 2009, 9:20 AM
  2. 'getting error in reloading tree'
    By priyankjoshi in forum Ext 2.x: Help & Discussion
    Replies: 2
    Last Post: 23 Jan 2009, 10:22 AM
  3. Howto use GroupingStore + JsonReader in a Grid?
    By jrcunha in forum Ext 2.x: Help & Discussion
    Replies: 4
    Last Post: 28 Oct 2008, 7:45 AM
  4. Howto use GroupingStore with JsonReader configured purely with metadata
    By johughes in forum Ext 2.x: Help & Discussion
    Replies: 1
    Last Post: 21 May 2008, 6:04 PM

Tags for this Thread

film izle

hd film izle

film sitesi

takipci kazanma sitesi

takipci kazanma sitesi

güzel olan herşey

takipci alma sitesi

komik eğlenceli videolar