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