I have a modal edit dialog in my jqgrid. After submit I display an success/error message to the user and then after a delay I make the error message dissapper.
afterSubmit: function (response, postdata) {
if(response.status == 200){
//---how to disable all controls here--------------------
$(".topinfo").html("<span style='color: green;font-weight: bold;'>Updates saved.</span>");
var tinfoel = $(".tinfo").show();
tinfoel.delay(5000).fadeOut();
//---how to hide modal dialog here---------------------------
return [true,''];
} else {
return [false,"<span style='color: red;font-weight: bold;'>An error occurred whilst attempting to save.</span>"];
}
}
What I would like to do is to disable all controls in the edit dialog as soon as I know the update was siccessful and then after the delay in addition to making the success message disappear I want to make the edit dialog dissappear.
Can someone help me with how to do this please?
thanks