1. #1
    Touch Premium Member
    Join Date
    Sep 2010
    Location
    Chicago, IL
    Posts
    40
    Vote Rating
    1
    scgrif32 is on a distinguished road

      0  

    Question Unanswered: How to refresh grid in another IE window?

    Unanswered: How to refresh grid in another IE window?


    Hello,

    I have developed an application using the MVC architecture. I previously had two views (Grid panel, modal window) that allowed me to do the following:
    • Grid and modal window form shared the same store.
    • When a row was double clicked in the grid the "itemdblclick" event is captured and opened the modal window.
    • The modal window contained a form, which was populated with the data that was contained in the row the user double clicked on.
    • When the user clicked on "submit" the form data was sent to the server via Ext Direct and upon successful form submission I reloaded the grid that spawned the modal window and closed the modal window.
    The requirement was for the modal window to be a separate page all together so I created an entirely new viewport that used the view that was previously displayed in the modal window. I figured out how to populate the form with the grid data but have not figured out how to refresh the grid so the updated record in the store will reflect in the grid view.

    I've read that the grid should reload (refresh) itself whenever the store is updated but that is not the case. I can successfully update the store with the new record(s) but the grid that spawned the new window does not reflect those changes upon successful submission.

    Have I overlooked something?

    Thanks in advance,

    Shawn

  2. #2
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    36,795
    Answers
    3466
    Vote Rating
    834
    mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute

      0  

    Default


    Did you open the window from your app?
    Mitchell Simoens @SenchaMitch
    Sencha Inc, Senior Forum Manager
    ________________
    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 in print!

    When posting code, please use BBCode's CODE tags.

  3. #3
    Touch Premium Member
    Join Date
    Sep 2010
    Location
    Chicago, IL
    Posts
    40
    Vote Rating
    1
    scgrif32 is on a distinguished road

      0  

    Default


    The double click event called a function in my controller that called window.open(URL). The requirement was to open a new browser window not a popup (modal) window.Everything I've seen on the web and Sencha examples used Ext.window to creat a modal window which was still aware of the components that were available in the parent window which is not the case under these circumstances unless I've made a false conclusion?Please help if possible.Thank you,Shawn

  4. #4
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    36,795
    Answers
    3466
    Vote Rating
    834
    mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute

      0  

    Default


    So you can keep a reference to that window you opened and therefore have access to it's document to get the store.
    Mitchell Simoens @SenchaMitch
    Sencha Inc, Senior Forum Manager
    ________________
    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 in print!

    When posting code, please use BBCode's CODE tags.

  5. #5
    Touch Premium Member
    Join Date
    Sep 2010
    Location
    Chicago, IL
    Posts
    40
    Vote Rating
    1
    scgrif32 is on a distinguished road

      0  

    Default


    Mitchell,

    I know I can get a reference to the window that is open by assigning it to a variable but from there is where I am slightly confused.

    var win = window.open(url);

    ????

    What I would like to do is when the form returns "success: true" that I could refresh the grid on the window that contained the variable "win" since it's the grid I would need to reload.

    Any suggestions?

    Thanks,

    Shawn

  6. #6
    Touch Premium Member
    Join Date
    Sep 2010
    Location
    Chicago, IL
    Posts
    40
    Vote Rating
    1
    scgrif32 is on a distinguished road

      0  

    Default


    Mitchell,

    I have a reference to the parent of the child window using "window.opener.*". The question I have is "how" do I get a reference to the grid object and call any of the methods available to the grid using "window.opener".

    I've thought of using a hidden button and trigger the Ext JS code from there:
    • Get a reference to the panel
    • Call gridView().refresh()
    and go from there.

    I am totally at a lose when it comes to what I should do when using the "window.opener" method and how to reference the grid panel in the parent window.

    Please help!!!

    - Shawn

Thread Participants: 1

Tags for this Thread

Turkiyenin en sevilen filmlerinin yer aldigi xnxx internet sitemiz olan ve porn sex tarzi bir site olan mobil porno izle sitemiz gercekten dillere destan bir durumda herkesin sevdigi bir site olarak tarihe gececege benziyor. Sitenin en belirgin ozelliklerinden birisi de Turkiyede gercekten kaliteli ve muntazam, duzenli porno izle siteleri olmamasidir. Bu yuzden iste. Ayrica en net goruntu kalitesine sahip adresinde yayinlanmaktadir. Mesela diğer sitelerimizden bahsedecek olursak, en iyi hd porno video arşivine sahip bir siteyiz. "The Best anal porn videos and slut anus, big asses movies set..." hd porno faketaxi