2 <!-- Application: Evergreen Staff Client -->
3 <!-- Screen: Main, Authentication Window -->
5 <!-- ///////////////////////////////////////////////////////////////////////////////////////////////////////////// -->
7 <?xml-stylesheet href="chrome://global/skin/" type="text/css"?>
8 <?xml-stylesheet href="chrome://open_ils_staff_client/skin/global.css" type="text/css"?>
9 <?xml-stylesheet href="chrome://open_ils_staff_client/skin/auth.css" type="text/css"?>
11 <!-- ///////////////////////////////////////////////////////////////////////////////////////////////////////////// -->
13 <!DOCTYPE window PUBLIC "" ""[
14 <!--#include virtual="/opac/locale/en-US/lang.dtd"-->
17 <!-- ///////////////////////////////////////////////////////////////////////////////////////////////////////////// -->
19 <?xul-overlay href="/xul/server/OpenILS/util_overlay.xul"?>
22 onload="try { data_init(); } catch(E) { alert(E); }"
23 title="&staff.auth.title;"
24 xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
27 <!-- ///////////////////////////////////////////////////////////////////////////////////////////////////////////// -->
29 <script type="text/javascript">var myPackageDir = 'open_ils_staff_client'; var IAMXUL = true; var g = {};</script>
30 <scripts id="openils_util_scripts"/>
32 <script type="text/javascript" src="chrome://open_ils_staff_client/content/main/lang.js"/>
33 <script type="text/javascript" src="/xul/server/main/lang.js"/>
34 <script type="text/javascript" src="chrome://open_ils_staff_client/content/main/JSAN.js"/>
37 dump("entities['lang.version'] = " + entities['lang.version'] + '\n');
39 function data_init() {
41 netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect");
43 if (typeof JSAN == 'undefined') {
45 "The JSAN library object is missing."
48 /////////////////////////////////////////////////////////////////////////////
50 JSAN.errorLevel = "die"; // none, warn, or die
51 JSAN.addRepository('/xul/server/');
53 // load these just so they'll get cached
54 JSAN.use('util.barcode'); JSAN.use('util.controller'); JSAN.use('util.deck'); JSAN.use('util.exec');
55 JSAN.use('util.fm_utils'); JSAN.use('util.list'); JSAN.use('util.network'); JSAN.use('util.sound');
56 JSAN.use('util.widgets'); JSAN.use('util.browser'); JSAN.use('util.error'); JSAN.use('util.file');
57 JSAN.use('util.functional'); JSAN.use('util.money'); JSAN.use('util.print'); JSAN.use('util.text');
58 JSAN.use('util.window');
60 JSAN.use('patron.bills'); JSAN.use('patron.display'); JSAN.use('patron.holds'); JSAN.use('patron.items');
61 JSAN.use('patron.search_form'); JSAN.use('patron.search_result'); JSAN.use('patron.summary');
62 JSAN.use('patron.util');
64 JSAN.use('circ.checkin'); JSAN.use('circ.checkout'); JSAN.use('circ.copy_status'); JSAN.use('circ.hold_capture');
65 JSAN.use('circ.in_house_use'); JSAN.use('circ.print_list_template_editor'); JSAN.use('circ.util');
67 JSAN.use('cat.copy_browser'); JSAN.use('cat.copy_buckets'); JSAN.use('cat.record_buckets');
68 JSAN.use('cat.util'); JSAN.use('cat.z3950');
72 JSAN.use('OpenILS.data');
73 g.data = new OpenILS.data()
74 g.data.on_error = xulG.auth.logoff;
75 g.data.entities = entities;
76 g.data.stash('entities');
79 g.data.session.key = xulG.auth.session.key;
80 g.data.session.authtime = xulG.auth.session.authtime;
81 g.data.stash('session');
82 g.data.on_complete = function () {
84 g.data.stash('list','hash','tree','temp','cached_request');
90 var n = Number( new Date() );
91 for (var i in g.data.cached_request) {
92 if (g.data.cached_request[i].expire_time < n && g.data.cached_request[i].status != 'pending') remove_me.push(i);
94 dump('trimming ' + remove_me.length + ' requests from cache\n');
95 for (var i in remove_me) delete g.data.cached_request[i];
102 g.data._debug_stash();
104 document.getElementById('iframe').setAttribute(
106 urls.XUL_OFFLINE_GENERATE_WIDGETS
109 document.getElementById('caption').setAttribute('label','Data loaded.');
111 xulG.window.open(urls.XUL_MENU_FRAME
112 + '?server='+window.escape(xulG.url),
113 'main'+xulG.window.window_name_increment(),'chrome,resizable'
120 g.data.init_observer_functions();
126 <groupbox id="data_groupbox" flex="1" class="my_overflow">
127 <caption id="caption" label="Loading data..."/>
128 <description id="data_progress"/>
129 <iframe id="iframe" />