[CLOSED] Updated two grid post to handler question

  1. #1

    [CLOSED] Updated two grid post to handler question

    I am in the process of updating some old code and ran in to a problem with the two grid post to handler (reference http://forums.ext.net/showthread.php...Handler-pop-up).
    <Listeners>
    <Save Handler="Ext.Msg.alert('Submit','Submit successful'); window.location = 'Main.aspx';"/>
    <CommitDone Handler="this.refresh();"/>
    <SaveException Handler="Ext.Msg.alert('Submit','Submit failure: ' + e.message);" />
    </Listeners>
    I changed the listener save event from the store to the Toolbar button click handler event (the previous model seems to have changed). I now get the pop-up "Operation was successful" with the "Ok" button. I need to refresh the page when the "Ok" button is clicked and the Button Click Handler event doesn't accept the window.location argument.
    Last edited by Daniil; Apr 01, 2015 at 8:11 PM. Reason: [CLOSED]
  2. #2
    I just added window.location into the submitData function in the js.
     
    submitData: function (source) {
                  source.submitData(null, {
                    url: "WebServices/SubmitHandler.ashx",
                    method: "POST",
                    success: function () {
                      Ext.Msg.alert("Submit", "Operation was successful");
                      window.location = 'main.aspx';
                    },
                    failure: function (response) {
                      Ext.Msg.alert("Error", response.responseText);
                    }
                  })

Similar Threads

  1. Replies: 0
    Last Post: Aug 14, 2012, 2:54 PM
  2. Replies: 0
    Last Post: Aug 14, 2012, 2:48 PM
  3. [CLOSED] question about the #{} notation in Handler
    By T3rryChan in forum 2.x Legacy Premium Help
    Replies: 1
    Last Post: May 02, 2012, 12:01 PM
  4. Replies: 2
    Last Post: Jan 16, 2012, 10:34 AM
  5. [CLOSED] How to update all updated grid info in Editable Grid?
    By rnachman in forum 1.x Legacy Premium Help
    Replies: 4
    Last Post: Dec 06, 2011, 3:56 PM

Posting Permissions