Gelmiş geçmiş en büyük porno sitemiz olan 2pe de her zaman en kaliteli pornoları sunmayı hedefledik. Diğer video sitemiz olan vuam da ise hd porno ağırlıklı çalışmalara başladık.

Hybrid View

  1. #1
    Ext User
    Join Date
    Aug 2010
    Posts
    23
    Vote Rating
    0
    pouli is on a distinguished road

      0  

    Default Unanswered: JsonReader and recordType is undefined

    Unanswered: JsonReader and recordType is undefined


    Hello,

    I am trying to do my first JsonStore to work but I keep receiving: recordType is undefined.
    Here is the the interesting part:

    var TestRecord = Ext.data.Record.create([ // creates a subclass of Ext.data.Record
    {name: 'lanID'},
    {name: 'translation'}
    ]);

    var writer = new Ext.data.JsonWriter({
    encode: true,
    writeAllFields : true
    });

    var reader = new Ext.data.JsonReader({
    totalProperty: 'total',
    successProperty: 'success',
    root: 'data',
    idProperty: 'lanID'
    },
    TestRecord);

    var proxy = new Ext.data.HttpProxy({
    api: {
    read : '/ajax/remote?doAction=AJAX_saveAdditionalRemark&action=read',
    create : '/ajax/remote?doAction=AJAX_saveAdditionalRemark&action=create',
    update: '/ajax/remote?doAction=AJAX_saveAdditionalRemark&action=update',
    destroy: '/ajax/remote?doAction=AJAX_saveAdditionalRemark&action=destroy'
    }
    });

    var propertyStore = new Ext.data.JsonStore({
    id: 'user',
    autoLoad: false,
    proxy: proxy,
    writer: writer,
    reader: reader,
    autoSave: false
    });

    propertyStore.load();

    When I execute this I can see form the firebug that the
    "var s = this.meta, Record = this.recordType,"

    Record is undefined. Although I specify the type at the reader and I have tried specify the fields at the store with no success.

    Any help would be appreciated.
    Thank you
    Last edited by pouli; 6 Oct 2010 at 8:02 AM. Reason: Changed "RecordType is undefined" --> Record is undefined

  2. #2
    Sencha - Community Support Team Condor's Avatar
    Join Date
    Mar 2007
    Location
    The Netherlands
    Posts
    24,246
    Answers
    1
    Vote Rating
    80
    Condor has much to be proud of Condor has much to be proud of Condor has much to be proud of Condor has much to be proud of Condor has much to be proud of Condor has much to be proud of Condor has much to be proud of Condor has much to be proud of

      0  

    Default


    JsonStore doesn't have a 'reader' config option. You should use a normal Store instead.

  3. #3
    Ext User
    Join Date
    Aug 2010
    Posts
    23
    Vote Rating
    0
    pouli is on a distinguished road

      0  

    Default


    Hello Condor,

    yes I have found a way around this by using metadata form the server.
    Your post explains better to me why jsonstore was not working with my reader.
    It is interesting though that there is no error message when I try to set my reader.

    Thank you again for the explanation I will take this into account for similar future problems that I may encounter.

Similar Threads

  1. [solved] JsonStore.recordType returns undefined
    By flanders in forum Ext 3.x: Help & Discussion
    Replies: 3
    Last Post: 21 Jun 2010, 2:31 AM
  2. [1.1.1] JsonReader: mapping to undefined element
    By andrei.neculau in forum Ext 1.x: Bugs
    Replies: 6
    Last Post: 17 Sep 2009, 11:57 PM
  3. Dynamic recordType for JsonReader in Store
    By cboden in forum Ext 2.x: Help & Discussion
    Replies: 2
    Last Post: 6 Jun 2008, 9:59 AM
  4. Replies: 4
    Last Post: 2 Jan 2008, 3:17 PM

Thread Participants: 1

Tags for this Thread