Save load before loading the main ViewPort application

I have a problem. I have a store that I need to download before my ViewPort apps get called. But when I have

autoCreateViewPort : true 

My store loads after ViewPort, which will not work. I need to download the current custom model or store before my ViewPort apps are presented. Since my ViewPort panels are loading, data from the Store is being used. Any ideas on the show. Can I make sure the store is loaded before creating and displaying the ViewPort app?

+7
source share
1 answer

You can insert an Ext.onReady block inside it Ext.onReady

  • create a store
  • create a function and create Ext.application inside this function
  • attach a listener to the store load event with the { single: true } option and the above function as a callback

I have never tested it, but it should work.

Another (and recommended) option is to use your own viewport and load the repository into it. There you can track the work of the download in the same way.

+6
source

All Articles