From 2a08f1878e0a3cabc9598904683025a259a92c9d Mon Sep 17 00:00:00 2001 From: phasefx Date: Tue, 6 Dec 2005 21:30:39 +0000 Subject: [PATCH] opac git-svn-id: svn://svn.open-ils.org/ILS/trunk@2240 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- Open-ILS/xul/staff_client/server/main/menu.js | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/Open-ILS/xul/staff_client/server/main/menu.js b/Open-ILS/xul/staff_client/server/main/menu.js index e10715eb0b..b5f2ffc870 100644 --- a/Open-ILS/xul/staff_client/server/main/menu.js +++ b/Open-ILS/xul/staff_client/server/main/menu.js @@ -51,6 +51,12 @@ main.menu.prototype = { function() { obj.set_tab('/xul/server/patron/patron_barcode_entry.xul?session='+obj.w.escape(session)); } + ], + 'cmd_search_opac' : [ + ['command','keypress'], + function() { + obj.set_tab('http://dev.gapines.org/',{},{ 'authtoken' : session }); + } ] }; @@ -144,14 +150,15 @@ main.menu.prototype = { tab.hidden = false; try { if (focus) this.view.tabs.selectedIndex = tc; - this.set_tab('data:text/html,

Hello World

',tc); + this.set_tab('data:text/html,

Hello World

',{ 'index' : tc }); } catch(E) { this.error.sdump('D_ERROR',E); } }, - 'set_tab' : function(url,idx) { - if (!idx) idx = this.view.tabs.selectedIndex; + 'set_tab' : function(url,params,content_params) { + var idx = this.view.tabs.selectedIndex; + if (typeof params.index != 'undefined') idx = params.index; var tab = this.view.tabs.childNodes[ idx ]; var panel = this.view.panels.childNodes[ idx ]; while ( panel.lastChild ) panel.removeChild( panel.lastChild ); @@ -159,6 +166,10 @@ main.menu.prototype = { frame.setAttribute('flex','1'); frame.setAttribute('src',url); panel.appendChild(frame); + if (content_params) { + frame.contentWindow.IAMXUL = true; + frame.contentWindow.xulG = content_params; + } } } -- 2.43.2