]> git.evergreen-ils.org Git - working/Evergreen.git/blob - Open-ILS/xul/staff_client/server/circ/print_list_template_editor.xul
new way of handling entities for remote xul
[working/Evergreen.git] / Open-ILS / xul / staff_client / server / circ / print_list_template_editor.xul
1 <?xml version="1.0"?>
2 <!-- Application: Evergreen Staff Client -->
3 <!-- Screen: Example Template for remote xul -->
4
5 <!-- ///////////////////////////////////////////////////////////////////////////////////////////////////////////// -->
6 <!-- STYLESHEETS -->
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="/xul/server/skin/global.css" type="text/css"?>
10
11 <!-- ///////////////////////////////////////////////////////////////////////////////////////////////////////////// -->
12 <!-- LOCALIZATION -->
13 <!DOCTYPE window PUBLIC "" ""[
14         <!--#include virtual="/opac/locale/en-US/lang.dtd"-->
15 ]>
16
17 <!-- ///////////////////////////////////////////////////////////////////////////////////////////////////////////// -->
18 <!-- OVERLAYS -->
19 <?xul-overlay href="/xul/server/OpenILS/util_overlay.xul"?>
20
21 <window id="print_list_win" 
22         onload="try { my_init(); } catch(E) { alert(E); }"
23         xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
24
25         <!-- ///////////////////////////////////////////////////////////////////////////////////////////////////////////// -->
26         <!-- BEHAVIOR -->
27         <script type="text/javascript">
28                 var myPackageDir = 'open_ils_staff_client'; var IAMXUL = true; var g = {};
29         </script>
30         <scripts id="openils_util_scripts"/>
31
32         <script type="text/javascript" src="/xul/server/main/JSAN.js"/>
33         <script>
34         <![CDATA[
35                 function my_init() {
36                         try {
37                                 netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect");
38                                 if (typeof JSAN == 'undefined') { throw( "The JSAN library object is missing."); }
39                                 JSAN.errorLevel = "die"; // none, warn, or die
40                                 JSAN.addRepository('/xul/server/');
41                                 JSAN.use('util.error'); g.error = new util.error();
42                                 g.error.sdump('D_TRACE','my_init() for print_list.xul');
43
44                                 g.cgi = new CGI();
45                                 var session = g.cgi.param('session');
46
47                                 JSAN.use('circ.print_list_template_editor');
48                                 g.editor = new circ.print_list_template_editor();
49
50                                 g.editor.init( 
51                                         { 
52                                                 'session' : session,
53                                         } 
54                                 );
55
56                                 if (typeof window.xulG == 'object' && typeof window.xulG.set_tab_name == 'function') {
57                                         try { window.xulG.set_tab_name('Receipt Template Editor'); } catch(E) { alert(E); }
58                                 }
59
60                         } catch(E) {
61                                 var err_msg = "!! This software has encountered an error.  Please tell your friendly " +
62                                         "system administrator or software developer the following:\ncirc/print_list.xul\n" + E + '\n';
63                                 try { g.error.sdump('D_ERROR',err_msg); } catch(E) { dump(err_msg); }
64                                 alert(err_msg);
65                         }
66                 }
67
68         ]]>
69         </script>
70
71         <commandset id="print_list_cmds">
72                 <command id="cmd_broken" />
73         </commandset>
74
75         <groupbox id="main" flex="1">
76                 <caption label="Templates" />
77                 <hbox id="top_ui">
78                         <groupbox flex="1">
79                                 <caption label="ID" />
80                                 <hbox>
81                                         <label value="Name" accesskey="N" control="template_name_menu" />
82                                         <hbox id="template_name_menu_placeholder" flex="1"/>
83                                 </hbox>
84                                 <hbox>
85                                         <label value="Type" />
86                                         <hbox id="template_type_menu_placeholder" />
87                                 </hbox>
88                         </groupbox>
89                         <groupbox>
90                                 <caption label="Actions" />
91                                 <button id="preview" label="Preview" accesskey="P" />
92                                 <button id="save" label="Save" accesskey="S" />
93                                 <button id="delete" label="Delete" accesskey="D" />
94                                 <button id="macros" label="Macros" accesskey="M" />
95                         </groupbox>
96                 </hbox>
97                 <hbox flex="1">
98                         <groupbox flex="1">
99                                 <caption label="Preview" />
100                                 <iframe id="sample" flex="1"/>
101                         </groupbox>
102                         <vbox flex="1">
103                                 <groupbox flex="1">
104                                         <caption label="Header"/>
105                                         <textbox id="header" multiline="true" flex="1"/>
106                                 </groupbox>
107                                 <groupbox flex="1">
108                                         <caption label="Line Item"/>
109                                         <textbox id="line_item" multiline="true" flex="1"/>
110                                 </groupbox>
111                                 <groupbox flex="1">
112                                         <caption label="Footer"/>
113                                         <textbox id="footer" multiline="true" flex="1"/>
114                                 </groupbox>
115                         </vbox>
116                 </hbox>
117         </groupbox>
118
119 </window>
120