diff options
author | Rouslan Placella <rouslan@placella.com> | 2011-10-30 18:30:08 +0400 |
---|---|---|
committer | Rouslan Placella <rouslan@placella.com> | 2011-10-30 18:30:08 +0400 |
commit | f7cb55cb626158d81ac606927142d8f55444b9ff (patch) | |
tree | 2af5ef2fe9d90755dafbd1d5b49a76e1135dca88 /js/db_search.js | |
parent | 694c1cdf751e1fcbe2435087e3cea0dcd85ca458 (diff) |
Fixed bug #3430377 - Deleted search results remain visible
Diffstat (limited to 'js/db_search.js')
-rw-r--r-- | js/db_search.js | 24 |
1 files changed, 13 insertions, 11 deletions
diff --git a/js/db_search.js b/js/db_search.js index 79c444e856..f9a941643f 100644 --- a/js/db_search.js +++ b/js/db_search.js @@ -48,18 +48,20 @@ function deleteResult(result_path , msg , ajaxEnable){ { if(ajaxEnable) { + var $msg = PMA_ajaxShowMessage(PMA_messages['strDeleting']); /** Load the deleted option to the page*/ - $('#browse-results').load(result_path + " '"+'#result_query' + "'"); - $('#sqlqueryform').load(result_path + " '"+'#sqlqueryform' + "'"); - $('#togglequerybox').html(PMA_messages['strHideQueryBox']); - - /** Refresh the search results after the deletion */ - document.getElementById('buttonGo'). click(); - //PMA_ajaxShowMessage(PMA_messages['strDeleting']); - /** Show the results of the deletion option */ - $('#browse-results').show(); - $('#sqlqueryform').show(); - $('#togglequerybox').show(); + $('#browse-results').load(result_path + " '"+'#result_query' + "'", function () { // FIXME: no need for two ajax reqests here + $('#sqlqueryform').load(result_path + " '"+'#sqlqueryform' + "'", function () { // since they both fetch the same page + /** Refresh the search results after the deletion */ + document.getElementById('buttonGo').click(); + $('#togglequerybox').html(PMA_messages['strHideQueryBox']); + PMA_ajaxRemoveMessage($msg); + /** Show the results of the deletion option */ + $('#browse-results').show(); + $('#sqlqueryform').show(); + $('#togglequerybox').show(); + }); + }); } else { |