I have a ScriptTagProxy and I can get the data, but now I want to update the record. I provided a url but only one url. Do I have to process all actions (read, update, create, delete) using this URL? If yes: how does the action apply to the url? If not: how can I provide more urls?
Here is the code that I still have:
app.stores.entries = new Ext.data.Store({ model: "app.models.Entry", storeId: 'app.stores.entries', proxy: { type: 'scripttag', url: 'http://myurl.de/getEntries.php', extraParams: { username: Ext.util.JSON.decode(window.localStorage.getItem('settings')).username, password: Ext.util.JSON.decode(window.localStorage.getItem('settings')).password }, reader: { type: 'json' }, writer: { type: 'json' } } });
I read in the docs that you can pass the configuration object to the model save function for proxy settings.
So, I tried the following:
entry.save({ url: 'http://mysite.com/updateEntry.php', extraParams: { username: Ext.util.JSON.decode(window.localStorage.getItem('settings')).username, password: Ext.util.JSON.decode(window.localStorage.getItem('settings')).password, entry: entry },}
As you can see, the URL is provided. But I still get the error: Search error: you are using ServerProxy, but you did not specify it with the url. );
This behavior when using AjaxProxy or RestProxy, for example: (