Hybrid View
-
13 Nov 2012 9:53 AM #1
Unanswered: pb in handling loalStorage memory
Unanswered: pb in handling loalStorage memory
When i display my data from the store in a list , all my items are multiplied, each time i load my app (F5)
this code works perfectly well in 2.03 version, but in 2.1, the items are multipliedCode:var imagStore=Ext.create('Ext.data.Store', { model: 'CWFSE.model.Document',// use a model data: record.get('docs'), // set the store data as the doc array }); //ref to my list view this.getTest().setStore(imagStore);
Someone can help me with this ? Is this a bug or something i'm doing wrong ?
-
15 Nov 2012 6:04 AM #2Sencha - Senior Forum Manager
- Join Date
- Mar 2007
- Location
- St. Louis, MO
- Posts
- 33,684
- Vote Rating
- 435
- Answers
- 3111
So you keep creating the store and giving it data or do you let the store load?
Mitchell Simoens @SenchaMitch
Sencha Inc, Senior Forum Manager
________________
http://www.JSONPLint.com - Source to lint your JSONP!
Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
https://github.com/mitchellsimoens
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 services@sencha.com
Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is almost in print!
When posting code, please use BBCode's CODE tags.
-
15 Nov 2012 6:25 AM #3
It does not look like the error happends in the code you posted.
You can check your localStorage, by typing in the console: localStorage.
Look for the localstorage you are talking about and check at which point of your app it is multiplied.
Either you are doing an autosync, which is not working or whatever.
-
15 Nov 2012 12:05 PM #4
thanks but i finally found that an Idproperty was missing in my Model, and i could make it work


Reply With Quote