22 Oct 2012 5:23 AM #1
Unanswered: Pre-loading app data
I'm building an app & using a local storage store for some of the data.
I woud like to pre-load the store when the app originally loads, but then uses the data in local storage in future use of the app.
I have attempted to use the 'load' callback to check if there is any data present after load, & the load the defaults if not, however the check for whether the data exists seems to not see the data in initial app load. Each time I load the app it adds another copy of the default data set. Can anyone help me understand what I'm doing wrong?
Source code can be found here... http://pastebin.com/Ht3N9NhF
24 Oct 2012 5:10 AM #2
- Join Date
- Mar 2007
- Gainesville, FL
- Vote Rating
You shouldn't override the load method, you need to use the load eventMitchell 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 email@example.com
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.
24 Oct 2012 7:54 AM #3
OK, will do, but any hints on how I solve my problem about pre-loading data?