[open-ils-commits] r19947 - branches/rel_2_0/Open-ILS/web/js/dojo/openils (senator)
svn at svn.open-ils.org
svn at svn.open-ils.org
Mon Apr 4 12:37:21 EDT 2011
Author: senator
Date: 2011-04-04 12:37:18 -0400 (Mon, 04 Apr 2011)
New Revision: 19947
Modified:
branches/rel_2_0/Open-ILS/web/js/dojo/openils/XUL.js
Log:
Booking: in support of r19944, backport newer openils.XUL.newTabEasy() from
trunk as well
Modified: branches/rel_2_0/Open-ILS/web/js/dojo/openils/XUL.js
===================================================================
--- branches/rel_2_0/Open-ILS/web/js/dojo/openils/XUL.js 2011-04-04 16:33:24 UTC (rev 19946)
+++ branches/rel_2_0/Open-ILS/web/js/dojo/openils/XUL.js 2011-04-04 16:37:18 UTC (rev 19947)
@@ -35,7 +35,9 @@
xulG.new_tab(path, tabInfo, options);
}
- openils.XUL.newTabEasy = function(url, tab_name, extra_content_params) {
+ openils.XUL.newTabEasy = function(
+ url, tab_name, extra_content_params, wrap_in_browser
+ ) {
var content_params = {
"session": openils.User.authtoken,
"authtime": openils.User.authtime
@@ -51,9 +53,20 @@
if (extra_content_params)
dojo.mixin(content_params, extra_content_params);
- xulG.new_tab(
- xulG.url_prefix(url), {"tab_name": tab_name}, content_params
- );
+ var loc = xulG.url_prefix(url);
+
+ if (wrap_in_browser) {
+ loc = urls.XUL_BROWSER + "?url=" + window.escape(loc);
+ content_params = dojo.mixin(
+ {
+ "no_xulG": false, "show_print_button": true,
+ "show_nav_buttons": true,
+ "passthru_content_params": extra_content_params
+ }, content_params
+ );
+ }
+
+ xulG.new_tab(loc, {"tab_name": tab_name}, content_params);
};
/**
More information about the open-ils-commits
mailing list