-
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
Similar Threads
-
By flanders in forum Ext 3.x: Help & Discussion
Replies: 3
Last Post: 21 Jun 2010, 2:31 AM
-
By andrei.neculau in forum Ext 1.x: Bugs
Replies: 6
Last Post: 17 Sep 2009, 11:57 PM
-
By cboden in forum Ext 2.x: Help & Discussion
Replies: 2
Last Post: 6 Jun 2008, 9:59 AM
-
By molasses in forum Ext 2.x: Bugs
Replies: 4
Last Post: 2 Jan 2008, 3:17 PM
Tags for this Thread
Sencha is used by over two million developers. Join the community, wherever you’d like that community to be
or Join Us