PDA

View Full Version : Error when store contains a memory proxy



WagsMax
2 Oct 2012, 2:20 PM
I get the error "Uncaught Ext.data.proxy.Server.buildUrl(): You are using a ServerProxy but have not supplied it with a url." when I add the following model to my app. I am able to define a memory proxy all the time in Sencha Touch, why not here in Ext JS?


Ext.define('ATMgo.store.Cases', {
extend: 'Ext.data.Store',
alias: 'store.cases',
requires: [
'ATMgo.model.Cases'
],


config: {
autoLoad: true,
model: 'ATMgo.model.Cases',
storeId: 'casesStore',
proxy: {
type: 'memory'
}
}
});

skirtle
2 Oct 2012, 2:23 PM
Does it work if you move it outside the config block?


Ext.define('ATMgo.store.Cases', {
extend: 'Ext.data.Store',
alias: 'store.cases',
requires: [
'ATMgo.model.Cases'
],

autoLoad: true,
model: 'ATMgo.model.Cases',
storeId: 'casesStore',
proxy: {
type: 'memory'
}
});