#1546 REPLACE statements (continued)
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / modules / admin / authtypes.tmpl
1 <!-- TMPL_INCLUDE NAME="doc-head-open.inc" -->
2 <title>Koha &rsaquo; Administration &rsaquo; <!-- TMPL_IF NAME="add_form" --><!-- TMPL_IF NAME="authtypecode" --> Authority Types &rsaquo; Modify authority type<!-- TMPL_ELSE --> Authority Types &rsaquo; Add authority type<!-- /TMPL_IF --><!-- TMPL_ELSE --><!-- TMPL_IF NAME="delete_confirm" -->Authority Types &rsaquo; Confirm Deletion of Authority Type<!-- TMPL_ELSE -->Authority Types<!-- /TMPL_IF --><!-- /TMPL_IF --></title>
3 <!-- TMPL_INCLUDE NAME="doc-head-close.inc" -->
4 <script type="text/javascript">
5 //<![CDATA[
6 /////////////////////////////////////////////////////////////////////////////////////////////////////////////////
7 function isNotNull(f,noalert) {
8         if (f.value.length ==0) {
9                 return false;
10         }
11         return true;
12 }
13 /////////////////////////////////////////////////////////////////////////////////////////////////////////////////
14 function toUC(f) {
15         var x=f.value.toUpperCase();
16         f.value=x;
17         return true;
18 }
19 /////////////////////////////////////////////////////////////////////////////////////////////////////////////////
20 function isNum(v,maybenull) {
21 var n = new Number(v.value);
22 if (isNaN(n)) {
23         return false;
24         }
25 if (maybenull==0 && v.value=='') {
26         return false;
27 }
28 return true;
29 }
30 /////////////////////////////////////////////////////////////////////////////////////////////////////////////////
31 function isDate(f) {
32         var t = Date.parse(f.value);
33         if (isNaN(t)) {
34                 return false;
35         }
36 }
37 /////////////////////////////////////////////////////////////////////////////////////////////////////////////////
38 function Check(f) {
39         var ok=1;
40         var _alertString="";
41         var alertString2;
42         if (f.authtypecode.value.length==0) {
43                 _alertString += "\n- " + _("Authority type : code missing");
44         }
45         if (!(isNotNull(window.document.Aform.authtypetext,1))) {
46                 _alertString += "\n- " + _("Description missing");
47         }
48         if (_alertString.length==0) {
49                 document.Aform.submit();
50         } else {
51                 alertString2  = _("Form not submitted because of the following problem(s)");
52                 alertString2 += "\n------------------------------------------------------------------------------------\n";
53                 alertString2 += _alertString;
54                 alert(alertString2);
55         }
56 }
57 //]]>
58 </script>
59 </head>
60 <body>
61 <!-- TMPL_INCLUDE NAME="header.inc" -->
62 <!-- TMPL_INCLUDE NAME="cat-search.inc" -->
63
64 <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" --><!-- TMPL_IF NAME="authtypecode" --> <a href="/cgi-bin/koha/admin/authtypes.pl">Authority Types</a> &rsaquo; Modify authority type<!-- TMPL_ELSE --> <a href="/cgi-bin/koha/admin/authtypes.pl">Authority Types</a> &rsaquo; Add authority type<!-- /TMPL_IF --><!-- TMPL_ELSE --><!-- TMPL_IF NAME="delete_confirm" --><a href="/cgi-bin/koha/admin/authtypes.pl">Authority Types</a> &rsaquo; Confirm Deletion of Authority Type<!-- TMPL_ELSE -->Authority Types<!-- /TMPL_IF --><!-- /TMPL_IF --></div>
65
66 <div id="doc3" class="yui-t2">
67    
68    <div id="bd">
69         <div id="yui-main">
70         <div class="yui-b">
71
72 <!-- TMPL_IF NAME="add_form" -->
73
74         <form action="<!-- TMPL_VAR NAME="script_name" -->" name="Aform" method="post">
75         <table>
76                 <!-- TMPL_IF NAME="authtypecode" -->
77                 <caption>Modify authority type</caption>
78         <!-- TMPL_ELSE -->
79                 <caption>Add authority type</caption>
80         <!-- /TMPL_IF -->
81                         <!-- TMPL_IF NAME="authtypecode" -->
82                                 <tr><td><label for="authtypecode">Authority type<label></td><td><input type="hidden" name="op" value="add_validate" />
83                 <input type="hidden" name="modif" value="1" /><input type="hidden" name="authtypecode" value="<!-- TMPL_VAR NAME="authtypecode" -->" /><!-- TMPL_VAR NAME="authtypecode" --></td></tr>
84                         <!-- TMPL_ELSE -->
85                                 <tr><td><label for="authtypecode">Authority type</label></td><td><input id="authtypecode" type="text" name="authtypecode" size="10" maxlength="10" onblur="toUC(this)" /></td></tr>
86                         <!-- /TMPL_IF -->
87                 <tr><td><label for="authtypetext">Description</label></td><td><input type="text" id="authtypetext" name="authtypetext" size="40" maxlength="80" value="<!-- TMPL_VAR NAME="authtypetext" ESCAPE="HTML" -->" /></td></tr>
88                 <tr><td><label for="summary">Summary</label></td><td><textarea id="summary" name="summary" cols="40" rows="10"><!-- TMPL_VAR NAME="summary" --></textarea></td></tr>
89                 <tr><td><label for="auth_tag_to_report">Report tag</label></td><td><input type="text" id="auth_tag_to_report" name="auth_tag_to_report" size="5" maxlength="3" value="<!-- TMPL_VAR NAME="auth_tag_to_report">" />Enter here the number of the tag that will be reported in the biblio (subfield by subfield). For example, in UNIMARC, enter 200 to report every 200 subfield in the 70x biblio</td></tr></table>
90         <input type="hidden" name="op" value="add_validate" />
91         <p><input type="submit" value="OK" onclick="Check(this.form); return false;" />
92                         </p>
93         </form>
94 <!-- /TMPL_IF -->
95
96 <!-- TMPL_IF NAME="delete_confirm" -->
97         <h2>Confirm Deletion of authority structure definition for <!-- TMPL_VAR NAME="authtypetext" --> (<!-- TMPL_VAR NAME="authtypecode" -->)</h2>
98         <!-- TMPL_IF NAME="total" -->
99                 <p>
100                         This record is used <!-- TMPL_VAR NAME="total" --> times
101                 </p>
102         <!-- /TMPL_IF -->
103
104                 <form action="<!-- TMPL_VAR NAME="script_name" -->" method="post">
105                         <input type="hidden" name="op" value="delete_confirmed" />
106                         <input type="hidden" name="authtypecode" value="<!-- TMPL_VAR NAME="authtypecode" -->" />
107                         <input type="submit" value="YES" />
108                 </form>
109                 <form action="<!-- TMPL_VAR NAME="script_name" -->" method="post">
110                         <input type="submit" value="NO" />
111                 </form>
112
113
114 <!-- /TMPL_IF -->
115
116 <!-- TMPL_IF NAME="else" -->
117 <h1>Authority Types</h1>
118 <p>Define authority types, then authority MARC structure in the same way you define itemtypes and biblio MARC tag structure. Authority values are managed through plugins</p>
119 <table>
120         <tr>
121                 <th>Code</th>
122                 <th>Description</th>
123                 <th>Summary</th>
124                 <th>Tag reported</th>
125                 <th>&nbsp;</th>
126                 <th>Edit</th>
127                 <th>Delete</th>
128         </tr>
129         
130         <!-- TMPL_LOOP NAME="loop" -->
131                 <tr>
132                         <td><!-- TMPL_VAR NAME="authtypecode" --></td>
133                         <td><!-- TMPL_VAR NAME="authtypetext" --></td>
134                         <td><!-- TMPL_VAR NAME="summary" --></td>
135                         <td><!-- TMPL_VAR NAME="auth_tag_to_report" --></td>
136                         <td><a href="auth_tag_structure.pl?authtypecode=<!-- TMPL_VAR NAME="authtypecode" -->" class="button parameters" >MARC structure</a></td>
137                         <td><a href="<!-- TMPL_VAR NAME="script_name" -->?op=add_form&amp;authtypecode=<!-- TMPL_VAR NAME="authtypecode" escape="HTML" -->">Edit</a></td>
138                         <td><a href="<!-- TMPL_VAR NAME="script_name" -->?op=delete_confirm&amp;authtypecode=<!-- TMPL_VAR NAME="authtypecode" escape="HTML" -->">Delete</a></td>
139                 </tr>
140         <!-- /TMPL_LOOP -->
141 </table>
142 <form action="<!-- TMPL_VAR NAME="script_name" -->" method="post">
143         <input type="hidden" name="op" value="add_form" />
144         <input type="submit" value="Add authority type" />
145         <!-- TMPL_IF NAME="previous" --><p><a href="<!-- TMPL_VAR NAME="previous" -->">&lt;&lt; Previous</a></p><!-- /TMPL_IF -->
146         <!-- TMPL_IF NAME="next" --><p><a href="<!-- TMPL_VAR NAME="next" -->">Next &gt;&gt;</a></p><!-- /TMPL_IF -->
147 </form>
148
149 <!-- /TMPL_IF -->
150 </div>
151 </div>
152 <div class="yui-b">
153 <!-- TMPL_INCLUDE NAME="admin-menu.inc" -->
154 </div>
155 </div>
156 <!-- TMPL_INCLUDE NAME="intranet-bottom.inc" -->