Refining navigation in MARC Framework pages; Fixing unfinished YUI-based toolbar...
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / modules / admin / marctagstructure.tmpl
1 <!-- TMPL_INCLUDE NAME="doc-head-open.inc" -->
2 <title>Koha &rsaquo; Administration &rsaquo;
3 <!-- TMPL_IF name="add_form" -->MARC Frameworks &rsaquo; <!-- TMPL_VAR name="action" --><!-- /TMPL_IF -->
4 <!-- TMPL_IF name="delete_confirm" -->MARC Frameworks &rsaquo; Confirm Deletion of Tag '<!-- TMPL_VAR name="searchfield" -->'<!-- /TMPL_IF -->
5 <!-- TMPL_IF name="delete_confirmed" -->MARC Frameworks &rsaquo;  Data Deleted<!-- /TMPL_IF -->
6 <!-- TMPL_IF name="else" -->MARC Frameworks<!-- /TMPL_IF --></title>
7 <!-- TMPL_INCLUDE NAME="doc-head-close.inc" -->
8 <script type="text/javascript">
9 //<![CDATA[
10     /////////////////////////////////////////////////////////////////////////////////////////////////////////////////
11     function isNotNull(f,noalert) {
12         if (f.value.length ==0) {
13                         return false;
14         }
15         return true;
16     }
17     /////////////////////////////////////////////////////////////////////////////////////////////////////////////////
18     function toUC(f) {
19         var x=f.value.toUpperCase();
20         f.value=x;
21         return true;
22     }
23     /////////////////////////////////////////////////////////////////////////////////////////////////////////////////
24     function isNum(v,maybenull) {
25     var n = new Number(v.value);
26     if (isNaN(n)) {
27         return false;
28         }
29     if (maybenull==0 && v.value=='') {
30         return false;
31     }
32     return true;
33     }
34     /////////////////////////////////////////////////////////////////////////////////////////////////////////////////
35     function isDate(f) {
36         var t = Date.parse(f.value);
37         if (isNaN(t)) {
38             return false;
39         }
40     }
41     /////////////////////////////////////////////////////////////////////////////////////////////////////////////////
42     function Check(f) {
43         var ok=1;
44         var _alertString="";
45         var alertString2;
46         if (f.tagfield.value.length==0) {
47             _alertString += "\n- " + _("tag number missing");
48         }
49         if (_alertString.length==0) {
50             document.Aform.submit();
51         } else {
52             alertString2  = _("Form not submitted because of the following problem(s)");
53             alertString2 += "\n------------------------------------------------------------------------------------\n";
54             alertString2 += _alertString;
55             alert(alertString2);
56         }
57     }
58     //]]>
59 </script>
60 </head>
61 <body>
62 <!-- TMPL_INCLUDE NAME="header.inc" -->
63 <!-- TMPL_INCLUDE NAME="cat-search.inc" -->
64
65 <div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> &rsaquo; <a href="/cgi-bin/koha/admin/admin-home.pl">Administration</a> &rsaquo; <!-- TMPL_IF name="add_form" --> <a href="/cgi-bin/koha/admin/marctagstructure.pl">MARC Frameworks</a> &rsaquo; <!-- TMPL_VAR name="action" --><!-- /TMPL_IF -->
66 <!-- TMPL_IF name="delete_confirm" --> <a href="/cgi-bin/koha/admin/marctagstructure.pl">MARC Frameworks</a> &rsaquo; Confirm Deletion of Tag '<!-- TMPL_VAR name="searchfield" -->'<!-- /TMPL_IF -->
67 <!-- TMPL_IF name="delete_confirmed" --> <a href="/cgi-bin/koha/admin/marctagstructure.pl">MARC Frameworks</a> &rsaquo; Data Deleted<!-- /TMPL_IF -->
68 <!-- TMPL_IF name="else" --><a href="/cgi-bin/koha/admin/biblio_framework.pl">MARC Frameworks</a> &rsaquo; <!-- TMPL_VAR NAME="frameworkcode" --> Framework<!-- /TMPL_IF --></div>
69
70 <div id="doc3" class="yui-t2">
71    
72    <div id="bd">
73         <div id="yui-main">
74         <div class="yui-b">
75
76 <h1>MARC Framework for <!-- TMPL_IF NAME="frameworkcode" --><!-- TMPL_VAR NAME="frameworktext" --> (<!-- TMPL_VAR NAME="frameworkcode" -->)<!-- TMPL_ELSE -->default MARC framework<!-- /TMPL_IF --></h1>
77
78
79 <!-- TMPL_IF NAME="add_form" -->
80
81     <form action="<!-- TMPL_VAR NAME="script_name" -->" name="Aform" method="post">
82         <input type="hidden" name="op" value="add_validate" />
83         <input type="hidden" name="frameworkcode" value="<!-- TMPL_VAR NAME="frameworkcode" -->" />
84         <h2><!-- TMPL_IF NAME="use-heading-flags-p" --><!-- TMPL_IF NAME="heading-modify-tag-p" -->Modify tag<!-- /TMPL_IF --><!-- TMPL_IF NAME="heading-add-tag-p" -->Add tag<!-- /TMPL_IF --><!-- TMPL_ELSE --><!-- TMPL_VAR NAME="action" --><!-- /TMPL_IF --></h2>
85          <p><label>Tag</label><input id="tagfield" type="text" name="tagfield" value="<!-- TMPL_VAR NAME="searchfield" -->" maxlength="3" size="3" /></p>    
86     <p><label for="liblibrarian">Label for lib</label><input type="text" id="liblibrarian" name="liblibrarian" value="<!-- TMPL_VAR NAME="liblibrarian" ESCAPE="HTML" -->" size="40" maxlength="100" /></p>
87     <p><label for="libopac">Label for opac</label><input type="text" id="libopac" name="libopac" value="<!-- TMPL_VAR NAME="libopac" ESCAPE="HTML" -->" size="40" maxlength="100" /></p>
88     <p><label for="repeatable">Repeatable</label><!-- TMPL_VAR NAME="repeatable" -->&nbsp;</p>
89     <p><label for="mandatory">Mandatory</label><!-- TMPL_VAR NAME="mandatory" -->&nbsp;</p>
90     <p><label for="authorised_value">Authorized value</label><!-- TMPL_VAR NAME="authorised_value" --> (if you select a value here, the indicators will be limited to the authorised value list)</p>
91         <p>
92             <input type="submit" value="Save Changes" onclick="Check(this.form)" />
93             <input type="submit" value="Cancel and Return to MARC Frameworks" onclick="location.href='<!-- TMPL_VAR NAME="script_name" -->?frameworkcode=<!-- TMPL_VAR NAME="frameworkcode" -->'; return false;" />
94         </p>
95     </form>
96 <!-- /TMPL_IF -->
97
98
99 <!-- TMPL_IF NAME="delete_confirm" -->
100
101 <h3>Confirm Deletion of Tag <em><!-- TMPL_VAR NAME="searchfield" --></em>?</h3>
102     <p>Tag: <!-- TMPL_VAR NAME="searchfield" --></p>
103     <p>Description: <!-- TMPL_VAR NAME="liblibrarian" --></p>
104     <form action="<!-- TMPL_VAR NAME="script_name" -->" method="post">
105         <input type="hidden" name="op" value="delete_confirmed" />
106         <input type="hidden" name="searchfield" value="<!-- TMPL_VAR NAME="searchfield" -->" /><input type="hidden" name="frameworkcode" value="<!-- TMPL_VAR NAME="frameworkcode" -->" />
107         <input type="submit" value="Yes, Delete this Tag" /></form>
108         
109         <form action="<!-- TMPL_VAR NAME="script_name" -->" method="post"><input type="submit" value="No, Do Not Delete" /></form>
110 <!-- /TMPL_IF -->
111
112 <!-- TMPL_IF NAME="delete_confirmed" -->
113
114     <div class="details"><h3>Tag Deleted</h3>
115     <form action="<!-- TMPL_VAR NAME="script_name" -->" method="post"><input type="hidden" name="frameworkcode" value="<!-- TMPL_VAR NAME="frameworkcode" -->" />
116     <input type="submit" value="Return to MARC Frameworks" />
117     </form>
118 <!-- /TMPL_IF -->
119 <!-- TMPL_IF NAME="framework_create" -->
120
121     <form action="<!-- TMPL_VAR NAME="script_name" -->" method="post">
122         <input type="hidden" name="op" value="framework_create_confirm" />
123         <input type="hidden" name="frameworkcode" value="<!-- TMPL_VAR NAME="frameworkcode" -->" />
124         Create framework for <!-- TMPL_VAR NAME="frameworkcode" --> (<!-- TMPL_VAR NAME="frameworktext" -->) using
125         <select name="existingframeworkcode">
126             <option value="">Default</option>
127         <!-- TMPL_LOOP NAME="existingframeworkloop" -->
128             <option value="<!-- TMPL_VAR NAME="value" -->"><!-- TMPL_VAR NAME="frameworktext" --></option>
129         <!-- /TMPL_LOOP -->
130         </select>
131         <input type="submit" value="OK" />
132     </form>
133 <!-- /TMPL_IF -->
134
135
136 <!-- TMPL_IF NAME="else" -->
137
138 <form name="f" action="<!-- TMPL_VAR NAME="script_name" -->" method="post">
139     <p><label for="frameworkcode">Framework</label>
140         <select id="frameworkcode" name="frameworkcode">
141             <option value="">Default</option>
142             <!-- TMPL_LOOP NAME="frameworkloop" -->
143                         <!-- TMPL_IF NAME="selected" -->
144                 <option value="<!-- TMPL_VAR NAME="value" -->" selected="selected"><!-- TMPL_VAR NAME="frameworktext" --></option>
145                                 <!-- TMPL_ELSE -->
146                 <option value="<!-- TMPL_VAR NAME="value" -->"><!-- TMPL_VAR NAME="frameworktext" --></option>
147                                 <!-- /TMPL_IF -->
148             <!-- /TMPL_LOOP -->
149         </select>
150     </p>
151     <p>
152         <label for="searchfield">Search for Tag</label>
153         <input type="text" name="searchfield" id="searchfield" value="<!-- TMPL_VAR NAME="searchfield" -->" />
154         <input type="submit" value="Search" />
155     </p>
156     <p>
157         <!-- TMPL_IF Name="select_display"-->
158             <label for="select_display">Display only used Tags/Subfields</label> <input type="checkbox" name="select_display" id="select_display" value="True" checked="checked"  onchange="this.form.submit();" />
159         <!-- TMPL_ELSE -->
160             <label for="select_display">Display only used Tags/Subfields</label> <input type="checkbox" name="select_display" id="select_display" value="True" onchange="this.form.submit();" />
161         <!--/TMPL_IF -->
162     </p>
163 </form>
164 <p>NOTE : if you change the link between a MARC subfield and a non-MARC field, ask your administrator to run misc/rebuildnonmarc.pl script.</p>
165
166     <table>
167     <tr>
168         <th>Tag</th>
169         <th>Lib</th>
170         <th>Repeatable</th>
171         <th>Mandatory</th>
172         <th>Auth value</th>
173         <th>Subfields</th>
174         <th>Edit</th>
175         <th>Delete</th>
176         </tr>
177
178     <!-- TMPL_IF NAME="select_display" -->
179         <!-- TMPL_LOOP NAME="loop" -->
180             <!-- TMPL_IF NAME="toggle" --><tr><!-- TMPL_ELSE --><tr class="highlight"><!-- /TMPL_IF -->
181             <td><!-- TMPL_VAR NAME="tagfield" --></td>
182             <td><!-- TMPL_VAR NAME="liblibrarian" --></td>
183             <td><!-- TMPL_IF NAME="repeatable" -->Yes<!-- TMPL_ELSE -->No<!-- /TMPL_IF --></td>
184             <td><!-- TMPL_IF NAME="mandatory" -->Yes<!-- TMPL_ELSE -->No<!-- /TMPL_IF --></td>
185             <td><!-- TMPL_VAR NAME="authorised_value" --></td>
186             <td><a href="<!-- TMPL_VAR NAME="subfield_link" -->">subfields</a></td>
187             <td><a href="<!-- TMPL_VAR NAME="edit" -->">Edit</a></td>
188             <td><a href="<!-- TMPL_VAR NAME="delete" -->">Delete</a></td>
189         </tr>
190       <!-- TMPL_IF NAME="toggle" --><tr><!-- TMPL_ELSE --><tr class="highlight"><!-- /TMPL_IF -->
191             <td>
192                 &nbsp;
193             </td>
194             <td colspan="7">
195                 <!-- TMPL_LOOP NAME="subfields" -->
196                     <p> Tab:<!-- TMPL_VAR NAME="tab" --> | $<!-- TMPL_VAR NAME="tagsubfield" -->
197                             <!-- TMPL_VAR NAME="liblibrarian" --> <!-- TMPL_IF NAME="kohafield" --><!-- TMPL_VAR NAME="kohafield" --><!--/TMPL_IF --><!-- TMPL_IF NAME="repeatable" -->, repeatable<!-- /TMPL_IF --><!-- TMPL_IF NAME="mandatory" -->, Mandatory<!-- /TMPL_IF --><!-- TMPL_IF NAME="seealso" -->, See <!-- TMPL_VAR name="seealso" --><!--/TMPL_IF --><!-- TMPL_IF NAME="authorised_value" -->, <!-- TMPL_VAR NAME="authorised_value" --><!--/TMPL_IF --><!-- TMPL_IF NAME="authtypecode" -->, <!-- TMPL_VAR NAME="authtypecode" --><!--/TMPL_IF --><!-- TMPL_IF NAME="value_builder" -->, <!-- TMPL_VAR NAME="value_builder" --><!--/TMPL_IF -->
198                     </p>
199                 <!-- /TMPL_LOOP -->
200             </td>
201         </tr>
202         <!-- /TMPL_LOOP -->
203     <!-- TMPL_ELSE -->
204     <!-- TMPL_LOOP NAME="loop" -->
205     <!-- TMPL_IF NAME="toggle" --><tr><!-- TMPL_ELSE --><tr class="highlight"><!-- /TMPL_IF -->
206         <td><!-- TMPL_VAR NAME="tagfield" --></td>
207         <td><!-- TMPL_VAR NAME="liblibrarian" --></td>
208         <td><!-- TMPL_IF NAME="repeatable" -->Yes<!-- TMPL_ELSE -->No<!-- /TMPL_IF --></td>
209         <td><!-- TMPL_IF NAME="mandatory" -->Yes<!-- TMPL_ELSE -->No<!-- /TMPL_IF --></td>
210         <td><!-- TMPL_VAR NAME="authorised_value" --></td>
211         <td><a href="<!-- TMPL_VAR NAME="subfield_link" -->">Subfields</a></td>
212         <td><a href="<!-- TMPL_VAR NAME="edit" -->">Edit</a></td>
213         <td><a href="<!-- TMPL_VAR NAME="delete" -->">Delete</a></td>
214     </tr>
215     <!-- /TMPL_LOOP -->
216     <!--/TMPL_IF -->
217     </table>
218     <!-- TMPL_IF NAME="isprevpage" -->
219             <a href="<!-- TMPL_VAR NAME="script_name" -->?offset=<!-- TMPL_VAR NAME="prevpage" -->&amp;searchfield=<!-- TMPL_VAR NAME="searchfield" -->&amp;frameworkcode=<!-- TMPL_VAR NAME="frameworkcode" --><!--TMPL_IF Name="select_display"-->&amp;select_display=True<!--/TMPL_IF -->">&lt;&lt; Previous</a>
220         <!-- /TMPL_IF -->
221     <form action="<!-- TMPL_VAR NAME="script_name" -->" method="post">
222         <input type="hidden" name="op" value="add_form" />
223                 <input type="hidden" name="searchfield" value="<!-- TMPL_VAR NAME="searchfield"-->" />
224         <input type="hidden" name="frameworkcode" value="<!-- TMPL_VAR NAME="frameworkcode" -->" />
225         <input type="submit" value="Add Tag" />
226     </form>
227         <!-- TMPL_IF NAME="nextpage" -->
228             <a href="<!-- TMPL_VAR NAME="script_name" -->?offset=<!-- TMPL_VAR NAME="nextpage" -->&amp;searchfield=<!-- TMPL_VAR NAME="searchfield" -->&amp;frameworkcode=<!-- TMPL_VAR NAME="frameworkcode" --><!--TMPL_IF Name="select_display"-->&amp;select_display=True<!--/TMPL_IF -->">Next &gt;&gt;</a>
229         <!-- /TMPL_IF -->
230
231 <!-- /TMPL_IF -->
232
233
234 </div>
235 </div>
236 <div class="yui-b">
237 <!-- TMPL_INCLUDE NAME="admin-menu.inc" -->
238 </div>
239 </div>
240 <!-- TMPL_INCLUDE NAME="intranet-bottom.inc" -->