From 34c69bc85a688a8116170f277846a3e5a163ab36 Mon Sep 17 00:00:00 2001 From: pines Date: Wed, 20 Sep 2006 15:51:38 +0000 Subject: [PATCH] instead of the old progress meter, show some textual progress information git-svn-id: svn://svn.open-ils.org/ILS/trunk@6164 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- .../chrome/content/OpenILS/data.js | 18 ++++++++++++++++++ .../staff_client/chrome/content/main/main.js | 4 +++- .../staff_client/chrome/content/main/main.xul | 4 +++- Open-ILS/xul/staff_client/server/main/data.xul | 8 ++++++-- 4 files changed, 30 insertions(+), 4 deletions(-) diff --git a/Open-ILS/xul/staff_client/chrome/content/OpenILS/data.js b/Open-ILS/xul/staff_client/chrome/content/OpenILS/data.js index 258df90bf7..7f7bdf9695 100644 --- a/Open-ILS/xul/staff_client/chrome/content/OpenILS/data.js +++ b/Open-ILS/xul/staff_client/chrome/content/OpenILS/data.js @@ -17,6 +17,17 @@ OpenILS.data.prototype = { 'temp' : '', + 'data_progress' : function(msg) { + try { + var x = document.getElementById('data_progress'); + if (x) { + x.appendChild( document.createTextNode( msg ) ); + } + } catch(E) { + this.error.sdump('D_ERROR',msg + '\n' + E); + } + }, + 'init' : function (params) { try { @@ -232,6 +243,7 @@ OpenILS.data.prototype = { JSAN.use('util.file'); var file = new util.file('print_list_templates'); obj.print_list_defaults(); + obj.data_progress('Default print templates set. '); if (file._file.exists()) { try { var x = file.get_object(); @@ -240,6 +252,7 @@ OpenILS.data.prototype = { obj.print_list_templates[i] = x[i]; } obj.stash('print_list_templates'); + obj.data_progress('Saved print templates retrieved from file. '); } } catch(E) { alert(E); @@ -254,6 +267,7 @@ OpenILS.data.prototype = { if (x) { obj.global_font_adjust = x; obj.stash('global_font_adjust'); + obj.data_progress('Saved font settings retrieved from file. '); } } catch(E) { alert(E); @@ -268,6 +282,7 @@ OpenILS.data.prototype = { if (x) { obj.no_sound = x; obj.stash('no_sound'); + obj.data_progress('Saved sound settings retrieved from file. '); } } catch(E) { alert(E); @@ -311,6 +326,7 @@ OpenILS.data.prototype = { obj.list[classname] = robj; obj.error.sdump_levels.D_SES_RESULT = level; convert(); + obj.data_progress('Retrieved list for ' + classname + ' objects. '); // if cacheable, store an offline copy /* FIXME -- we're going to revisit caching and do it differently if (cacheable) { @@ -347,6 +363,7 @@ OpenILS.data.prototype = { var robj = obj.network.simple_request('CIRC_MODIFIER_LIST',[]); if (typeof robj.ilsevent != 'undefined') throw(robj); obj.list.circ_modifier = robj; + obj.data_progress('Retrieved circ modifier list. '); } catch(E) { var error = 'Error: ' + js2JSON(E); obj.error.sdump('D_ERROR',error); @@ -361,6 +378,7 @@ OpenILS.data.prototype = { var robj = obj.network.simple_request('BILLING_TYPE_LIST',[]); if (typeof robj.ilsevent != 'undefined') throw(robj); obj.list.billing_type = robj; + obj.data_progress('Retrieved billing type list. '); } catch(E) { var error = 'Error: ' + js2JSON(E); obj.error.sdump('D_ERROR',error); diff --git a/Open-ILS/xul/staff_client/chrome/content/main/main.js b/Open-ILS/xul/staff_client/chrome/content/main/main.js index 1a623262ee..384b86323a 100644 --- a/Open-ILS/xul/staff_client/chrome/content/main/main.js +++ b/Open-ILS/xul/staff_client/chrome/content/main/main.js @@ -108,7 +108,9 @@ function main_init() { } if (G.data.ws_info && G.data.ws_info[G.auth.controller.view.server_prompt.value]) { - var deck = document.getElementById('main_deck'); + JSAN.use('util.widgets'); + var deck = document.getElementById('progress_space'); + util.widgets.remove_children( deck ); var iframe = document.createElement('iframe'); deck.appendChild(iframe); iframe.setAttribute( 'src', url + '/xul/server/main/data.xul' ); iframe.contentWindow.xulG = xulG; diff --git a/Open-ILS/xul/staff_client/chrome/content/main/main.xul b/Open-ILS/xul/staff_client/chrome/content/main/main.xul index 9baafd519c..b316fddbb8 100644 --- a/Open-ILS/xul/staff_client/chrome/content/main/main.xul +++ b/Open-ILS/xul/staff_client/chrome/content/main/main.xul @@ -153,7 +153,9 @@ - + +