PDA

View Full Version : grid crud using writer, how to save data from multi stores at one request?



jinjianhe
16 Jan 2012, 5:24 PM
extjs4 grid crud using writer, how to save data from multi stores at one request? can u give an example? thx. in the extjs3, there is an solution which is probably to write a beforewrite event handler for both stores that saves the passed data and returns false, so it doesn't actually make a request.
Next, you would call save() on both stores and make your own request using the data from both beforwrite handlers.
however in the extjs4 there does not have the beforewrite event.

mitchellsimoens
16 Jan 2012, 9:03 PM
You cannot. Ext.Direct can do this if the requests are made within a certain number of milliseconds which is configurable. The downside is you have server setup to use Ext.Direct.