Results 1 to 3 of 3

Thread: Store Bind

  1. #1

    Default Answered: Store Bind

    Hi,

    i was wondering, is there a way to find out when a store is bound to a panel.
    On afterrender the store of the panel still references a default store with a memory proxy.

    Example:

    Code:
    Ext.create('Ext.grid.Panel', {
        title: 'Simpsons',
        bind{
             store: '{MyStore}'
       },
        columns: [
            { text: 'Name',  dataIndex: 'name' },
            { text: 'Email', dataIndex: 'email', flex: 1 },
            { text: 'Phone', dataIndex: 'phone' }
        ],
        height: 200,
        width: 400,
        renderTo: Ext.getBody()
    });
    Thx in advance,
    Sebastian

  2. Hi Sebastian,


    I have this thread for the same subject: http://www.sencha.com/forum/showthre...nt-is-rendered


    I was advised to use the onBindStore method, which I had problems with, so currently I'm using Ext.defer(function(){},10); for everything that needs to be done.


    Hopefully they will get an event for this.

  3. #2
    Sencha Premium Member
    Join Date
    Jan 2013
    Location
    Chicago
    Posts
    123
    Answers
    16

    Default

    Hi Sebastian,


    I have this thread for the same subject: http://www.sencha.com/forum/showthre...nt-is-rendered


    I was advised to use the onBindStore method, which I had problems with, so currently I'm using Ext.defer(function(){},10); for everything that needs to be done.


    Hopefully they will get an event for this.

  4. #3

    Default

    Thanks for your answer.
    Timing that would be a way to work around it, but what if i have multiple/ a lot of stores in my viewModel. I think that would increase the timing of the binding, so you may have to adapt your timings in the deferred functions. Another solution i came up with is to completely abandon binding for stores that you want to initialize afterrender. I just defined my store inline.
    I think in general it would be nice to have a callback on the bind that is called after the store is bound.


    Greetings,
    Sebastian

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •