sarsnake
sarsnake

Reputation: 27723

Closing delete dialog in jqgrid

How can I manually close it after deleting a row manually in the jqgrid (locally), no server interaction.

I delete the row using $('#myGrid').jqGrid('delRowData', rowId); but the delete dialog stays open.

Upvotes: 0

Views: 1499

Answers (1)

Oleg
Oleg

Reputation: 222007

It's unclear why the Delete dialog need be close manually. It it's really needed it could be done with the code like

var grid_id = $.jgrid.jqID(this.p.id); // the id of the grid

$.jgrid.hideModal("#delmod" + grid, {
    gb: "#gbox_" + grid_id,
    jqm: true
});

Probably you try to use Delete form with local data. I described in the answer the trick with setting processing option to true which I described here. Another answer provide the code with the demo which implement local form editing. The answer is small modification of the more old answer which did the same with more old version of jqGrid. Probably the old answers referenced above will be helpful for you.

Upvotes: 2

Related Questions