-
2 Jan 2011 4:10 AM #1
copy data from one store to another
copy data from one store to another
Hi,
I have a localstorage which holds data as a cache. Everytime I start my webapp, i ask the server if new data is available. if so, I set up a store with jsonProxy, collect the data and copy it from this store to the localstorage.
Is there any better method then iterating over the jsonstore data and copy it record by record into the localstorage? This is not the fastest operation on the iphone and I currently try to find a way which performs faster than this..
Chriz
-
7 Apr 2011 10:37 AM #2
Was wondering myself, doesnt seem to be anything built-in really for this. I have something like the following:
Code:store2 = new Ext.data.Store(); store1.each(function(record){ store2.add(record.copy()); });
-
21 Dec 2011 10:03 AM #3
Thnx..
-
26 Oct 2012 8:47 AM #4
doubt
doubt
am not even able to iterate through the store
gives the below error
Uncaught TypeError: Cannot call method 'indexOf' of undefined
am using something like this
foodAllergiesGridStore.each(function(record){
//begg.add(record.copy());
console.log('asdf');
});
Similar Threads
-
Store copy
By anishanc in forum Ext 2.x: Help & DiscussionReplies: 3Last Post: 29 Jun 2009, 7:44 PM -
Copy data in Grid.
By sugen in forum Ext 2.x: Help & DiscussionReplies: 5Last Post: 30 Nov 2008, 11:30 PM -
take copy from store
By mnask in forum Ext 2.x: Help & DiscussionReplies: 1Last Post: 23 Mar 2008, 4:05 AM -
copy data store instead of reference (resolved)
By para in forum Ext 1.x: Help & DiscussionReplies: 3Last Post: 22 May 2007, 11:31 AM -
How to copy data in the clipboard using JavaScript?
By liotrox in forum Ext 1.x: Help & DiscussionReplies: 1Last Post: 22 Mar 2007, 7:00 AM


Reply With Quote