Base solution for your next web application
Open Closed

jtable inside a modal deleteAction #3342


User avatar
0
slapointe created

Hello When trying to invoke a deleteAction from a modal i get a Maximum Call stack exceeded error, the confirmation dialog appears behind the current modal.

i've attached two pictures, one after clicking the delete button, and one after closing the modal, showing the confirmation box. Upon trying to confirm deletion it will produce an undefined exception as the table and modal has been destroyed. relevant code:

(function () {
    app.modals.CreateOrEditDistributorModal = function () {
.....
this.init = function (modalManager) {
            _modalManager = modalManager;

            _$itemCodeTable.jtable({
                title: app.localize('ItemCodes'),

                paging: true,
                pageSize: 15,
                sorting: true,
                defaultSorting: 'Itemcode ASC',


                actions: {
                    listAction: {
                        method: _distributorService.getSkusForDistributor
                    },
                    deleteAction: {
                        method: _distributorService.deleteSkuForDistributor
                    }
                },
fields: { .......}

}


1 Answer(s)
  • User Avatar
    0
    ismcagdas created
    Support Team

    Hi,

    Since jTable uses jQuery UI, such functions does not work very well with bootstrap. Because of that, we implemented it differently in AspNet Zero, I suggest you to do it like that.

    Thanks.