Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
2048
igGridUpdating, RowEditTemplate and updating events
posted

Hi,

in this post http://es.infragistics.com/community/forums/t/75037.aspx, on the 10-29-2012 I asked about events to be caught in order to know when user clikced on OK, Cancel or Close button of a RowEditTemplate dialog.
It was IgniteUI 2012.2.

Now I re-ask, is there a better way than this one:

$("#grid_one").live('iggridupdatingroweditdialogclosed', function (event, ui) {
        if (event.buttons == 0) { // Ok button
            $("#grid_one").igGrid("saveChanges");
        }
    });

to catch user click buttons in IgniteUI 2013.1? Also because now I need to understand when user clicks OK button and when Close button...

All these is because calssic iggridupdatingeditrowended is not caught whe RowEditTemplate is enable...

Thanks,

Flavio M.

Parents
  • 23953
    Offline posted

    Hello Flavio,

    Currently there is no straightforward way to determine which button is clicked. However I can provide you with the following solution:

    rowEditDialogClosed: function (event, ui) {
    var $button = $(event.currentTarget).data("igButton");
    //Done or Cancel buttons clicked
    if ($button) {
    var buttonCaption = $button.options.labelText;
    if (buttonCaption === "Done") {

    $("#grid_one").igGrid("saveChanges");
    }
    }
    else {
    // Esc button pressed or X button clicked
    }
    }

    Best regards,
    Martin Pavlov
    Infragistics, Inc. 

Reply Children