1 <?xml version='1.0' encoding="UTF-8"?>
3 # Copyright (C) 2008 Georgia Public Library Service
4 # Bill Erickson <erickson@esilibrary.com>
5 # This program is free software; you can redistribute it and/or
6 # modify it under the terms of the GNU General Public License
7 # as published by the Free Software Foundation; either version 2
8 # of the License, or (at your option) any later version.
10 # This program is distributed in the hope that it will be useful,
11 # but WITHOUT ANY WARRANTY; without even the implied warranty of
12 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 # GNU General Public License for more details.
17 "-//W3C//DTD XHTML 1.0 Transitional//EN"
18 "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd" [
19 <!--#include virtual="/opac/locale/${locale}/lang.dtd"-->
22 <html xmlns='http://www.w3.org/1999/xhtml'>
24 <title>&staff.server.admin.org_unit_settings.title;</title>
25 <link type='text/css' rel='stylesheet' href='admin.css' />
26 <script type="text/javascript" src='/IDL2js?aou,aout,pgt,au,coust,aous,csg,coustl' />
27 <script type="text/javascript" djConfig="parseOnLoad: true,isDebug:false" src="/js/dojo/dojo/dojo.js" />
28 <script type="text/javascript" djConfig="parseOnLoad: true,isDebug:false" src="/js/dojo/dojo/openils_dojo.js" />
29 <script type="text/javascript" src='org_unit_settings.js' />
30 <script type="text/javascript" src="/xul/server/util/clipboard.js" />
31 <style type="text/css">
37 .form_table textarea {
54 background-color:#D9E8F9;
56 /*Standards compliant*/
57 border-bottom-left-radius:5px;
58 border-bottom-right-radius:5px;
60 /*Old staff client compliant, It could be worse, we could be using IE!*/
61 -moz-border-radius-bottomleft:5px;
62 -moz-border-radius-bottomright:5px;
76 <body class='tundra tall'>
77 <div dojoType='dijit.layout.LayoutContainer' orientation='vertical' class='tall'>
78 <div dojoType='dijit.layout.ContentPane' layoutAlign='top'>
79 <div id="toolbar1" dojoType="dijit.Toolbar">
80 <strong>&staff.server.admin.org_unit_settings.title;</strong>
82 <span dojoType="dijit.ToolbarSeparator" />
84 <span>&staff.server.admin.org_unit_settings.context_loc;</span>
85 <select dojoType='openils.widget.OrgUnitFilteringSelect' jsId='osContextSelector'
86 searchAttr='shortname' autocomplete='true' labelAttr='shortname' onchange='osChangeContext();' />
88 <span dojoType="dijit.ToolbarSeparator" />
90 <form id='searchform' onSubmit='return doSearch()'>
91 <input type='text' dojoType='dijit.form.TextBox' id='searchBox' />
92 <button type='submit' dojoType='dijit.form.Button'>&staff.server.admin.org_unit_settings.filter;</button>
93 <button dojoType='dijit.form.Button' onClick='clearSearch();'>&staff.server.admin.org_unit_settings.clear_filter;</button>
96 <span dojoType="dijit.ToolbarSeparator" />
98 <button dojoType='dijit.form.Button' onClick='osToJson();'>&staff.server.admin.org_unit_settings.export;</button>
99 <button dojoType='dijit.form.Button' onClick='osFromJson();'>&staff.server.admin.org_unit_settings.import;</button>
101 <span>&staff.server.admin.org_unit_settings.uninherited;</span>
103 <div dojoType="dijit.layout.ContentPane" layoutAlign='client'>
104 <div class='hide_me' id='no-perms'><b>&staff.server.admin.org_unit_settings.no_perms;</b></div>
106 <div dojoType="dijit.layout.ContentPane" layoutAlign='client' class='tall'>
108 var osGridLayout = [{
109 defaultCell: {styles: 'text-align: center;'},
111 { name: '&staff.server.admin.org_unit_settings.edit;',
112 value: '<a href="javascript:void(0);" onclick="osLaunchEditor(\'SETTING\');">&staff.server.admin.org_unit_settings.edit;</a>',
114 formatter : osFormatEditLink
116 { name: '&staff.server.admin.org_unit_settings.history;',
117 value: '<a href="javascript:void(0);" onclick="osLaunchHistory(\'SETTING\');">&staff.server.admin.org_unit_settings.history;</a>',
118 get: osGetHistoryLink,
119 formatter : osFormatHistoryLink
121 {name: '&staff.server.admin.org_unit_settings.group;', get: osGetGridData, field:'grp'},
122 {name: '&staff.server.admin.org_unit_settings.setting;', get: osGetGridData, field:'label', width:'auto', styles:'text-align:left;'},
123 {name: '&staff.server.admin.org_unit_settings.context;', get: osGetGridData, field:'context'},
124 {name: '&staff.server.admin.org_unit_settings.value;', get: osGetGridData, field:'value', width:'auto'},
128 <div dojoType='dojox.Grid' jsId='osGrid' />
133 <div dojoType="dijit.Dialog" jsId='osEditDialog' title="&staff.server.admin.org_unit_settings.edit_setting;">
134 <table class='form_table'>
136 <tr><td colspan='2' align='center'><div id='os-edit-name'/></td></tr>
137 <tr><td colspan='2' align='center'><div id='os-edit-desc' style='max-width:600px;'/></td></tr>
141 <td>&staff.server.admin.org_unit_settings.context;</td>
143 <select dojoType="openils.widget.OrgUnitFilteringSelect" jsId='osEditContextSelector'
144 searchAttr="shortname" autocomplete="true" labelAttr='shortname'>
149 <td>&staff.server.admin.org_unit_settings.value;</td>
151 <input dojoType='dijit.form.TextBox' jsId='osEditTextBox'/>
152 <input dojoType='dijit.form.CurrencyTextBox' jsId='osEditCurrencyTextBox'/>
153 <input dojoType='dijit.form.NumberTextBox' jsId='osEditNumberTextBox'/>
154 <select dojoType='dijit.form.FilteringSelect' jsId='osEditBoolSelect'>
155 <option value='true'>&common.true;</option>
156 <option value='false'>&common.false;</option>
158 <div id='os-edit-auto-widget'></div>
163 <button dojoType='dijit.form.Button' onclick='osEditSetting(true);'>&staff.server.admin.org_unit_settings.delete_setting;</button>
166 <button dojoType='dijit.form.Button' onclick='osEditSetting();'>&staff.server.admin.org_unit_settings.update_setting;</button>
171 </div> <!-- /edit dialog -->
173 <div dojoType="openils.widget.ProgressDialog" jsId="progressDialog" indeterminate="true" />
175 <!--i18n, use the &translation; here, then grab innerHTML in JS later.-->
176 <div id='proci18n' class='hidden'>&staff.server.admin.org_unit_settings.processing;</div>
177 <div id='noresults' class='hidden'>&staff.server.admin.org_unit_settings.no_results;</div>
178 <span id='os-true' class='hidden'>&common.true;</span>
179 <span id='os-false' class='hidden'>&common.false;</span>
180 <span id='os-copy' class='hidden'>&staff.server.admin.org_unit_settings.copy;</span>
183 <div id='jsonOutputDialog' dojoType='dijit.Dialog' jsId='osJSONOutDialog' title='&staff.server.admin.org_unit_settings.export;'>
184 <table class='form_table'>
185 <tr><td>&staff.server.admin.org_unit_settings.export_copy_label;</td></tr>
186 <tr><td><textarea id='jsonOutput' /></td></tr>
187 <tr><td><button dojoType='dijit.form.Button' onclick='osJsonOutputCopy();'>&staff.server.admin.org_unit_settings.copy;</button></td></tr>
192 <div id='jsonInputDialog' dojoType='dijit.Dialog' jsId='osJSONInDialog' title='&staff.server.admin.org_unit_settings.import;'>
193 <table class='form_table'>
194 <tr><td>&staff.server.admin.org_unit_settings.import_paste_label;</td></tr>
195 <tr><td><textarea id='jsonInput' /></td></tr>
196 <tr><td><button dojoType='dijit.form.Button' onclick='osJsonInputPaste();'>&staff.server.admin.org_unit_settings.paste;</button><button type='submit' dojoType='dijit.form.Button' onclick='osFromJsonSubmit();'>&staff.server.admin.org_unit_settings.submit;</button></td></tr>
200 <!--History Dialog-->
201 <div id="historyDialog" dojoType="dijit.Dialog" jsId="osHistDialog" title="&staff.server.admin.org_unit_settings.history;">
202 <span id='osHistName' />
204 <!--Headers grabbed from this table are put in the next one by the js.-->
205 <table id="histTitle" class="hidden">
207 <td>&staff.server.admin.org_unit_settings.history_date;</td>
208 <td>&staff.server.admin.org_unit_settings.history_unit;</td>
209 <td>&staff.server.admin.org_unit_settings.history_orig;</td>
210 <td>&staff.server.admin.org_unit_settings.history_new;</td>
214 <table class="form_table" id="historyData" />
217 <!--Displays alerts at the top of the screen, much nicer than alert() or dojo equiv.-->
218 <div class="message_container" id="msgCont">
219 <div class="message" id='msgInner' />