From e13d1c98503253299678207b2068bd45d55d597b Mon Sep 17 00:00:00 2001 From: Mike Taylor Date: Thu, 5 Dec 2013 11:48:02 +0000 Subject: [PATCH 1/1] Move invocation of run_auto_searches() from when DOM is ready to when service-proxy authentication has completed. As a result, that search now includes the relevant JSESSIONID, and consequently works consistently and deliberately rather than intermittently and accidentally. Fixes bug MKWS-69 ("Allow results area to auto-populate itself with results of a canned search") Remove extreme debugging output for my_onshow() --- tools/htdocs/mkws.js | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/tools/htdocs/mkws.js b/tools/htdocs/mkws.js index 62fed9a..ff67799 100644 --- a/tools/htdocs/mkws.js +++ b/tools/htdocs/mkws.js @@ -261,7 +261,6 @@ function my_onshow(data) { // navi var results = document.getElementById("mkwsRecords"); - debug("my_onshow(" + JSON.stringify(data) + ")"); var html = []; for (var i = 0; i < data.hits.length; i++) { @@ -1016,6 +1015,7 @@ function mkws_service_proxy_auth(auth_url, auth_domain) { debug("Service proxy auth successfully done"); mkws.authenticated = true; + run_auto_searches(); }); } @@ -1253,8 +1253,6 @@ $(document).ready(function() { mkws_config.error = e.message; // alert(e.message); } - - run_auto_searches(); }); })(jQuery); -- 1.7.10.4