2 Jul 2012 8:18 PM #1
Unanswered: copy jsonp store data
i struggle to get two stores with identical values retrieved by a single jsonp call.
i tried using an onload store listener and then copy the value manually into the other store, but this doesnt work since the user has to be able to refresh the stores manually (where the listeners doesnt get called for some reason).
hope this makes any sense, right now i am simply doing two requests, but as the json content grows, the lovely performance is suffering...
the reason for the required identical store is a global search function for the main store.
4 Jul 2012 4:56 AM #2
- Join Date
- Mar 2007
- Gainesville, FL
- Vote Rating
So both have a proxy on it right? On load you loop through the records and add the data to the other one right?Mitchell Simoens @SenchaMitch
Sencha Inc, Senior Software Engineer
Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/
Need more help with your app? Hire Sencha Services firstname.lastname@example.org
Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is in print!
When posting code, please use BBCode's CODE tags.
4 Jul 2012 7:41 PM #3
well, at the moment both have the same proxies and same model defined. but thats not an optimized way to do it right?
i want to only have one proxy for the "main" store and then just copy all its data 1:1 into the "search" store.
i tried the onload handler with the copy function. it worked, but only until the user refreshes the "main" store manually.