Moving </head><body> into body of templates so that js and css can be embedded per...
[koha_ffzg] / koha-tmpl / intranet-tmpl / prog / en / modules / admin / biblio_framework.tmpl
1 <!-- TMPL_INCLUDE NAME="doc-head-open.inc" -->
2 <title>Koha &rsaquo; System Administration: <!-- TMPL_IF NAME="add_form" --><!-- TMPL_IF NAME="frameworkcode" -->Modify framework text<!-- TMPL_ELSE -->Add framework<!-- /TMPL_IF --><!-- /TMPL_IF --><!-- TMPL_IF NAME="delete_confirm" -->Delete Framework for <!-- TMPL_VAR NAME="frameworktext" --> (<!-- TMPL_VAR NAME="frameworkcode" -->)?<!-- /TMPL_IF --><!-- TMPL_IF NAME="else" -->Biblio Framework<!-- /TMPL_IF --></title>
3 <!-- TMPL_INCLUDE NAME="doc-head-close.inc" -->
4 </head>
5 <body>
6 <!-- TMPL_INCLUDE NAME="header.inc" -->
7
8 <!-- TMPL_INCLUDE NAME="menu-admin.inc" -->
9
10 <script language="javascript" type="text/javascript">
11 /////////////////////////////////////////////////////////////////////////////////////////////////////////////////
12 function isNotNull(f,noalert) {
13     if (f.value.length ==0) {
14         return false;
15     }
16     return true;
17 }
18 /////////////////////////////////////////////////////////////////////////////////////////////////////////////////
19 function toUC(f) {
20     var x=f.value.toUpperCase();
21     f.value=x;
22     return true;
23 }
24 /////////////////////////////////////////////////////////////////////////////////////////////////////////////////
25 function isNum(v,maybenull) {
26 var n = new Number(v.value);
27 if (isNaN(n)) {
28     return false;
29     }
30 if (maybenull==0 && v.value=='') {
31     return false;
32 }
33 return true;
34 }
35 /////////////////////////////////////////////////////////////////////////////////////////////////////////////////
36 function isDate(f) {
37     var t = Date.parse(f.value);
38     if (isNaN(t)) {
39         return false;
40     }
41 }
42 /////////////////////////////////////////////////////////////////////////////////////////////////////////////////
43 function Check(f) {
44     var ok=1;
45     var _alertString="";
46     var alertString2;
47     if (f.frameworkcode.value.length==0) {
48         _alertString += "\n- " + _("Framework code missing");
49     }
50     if (!(isNotNull(window.document.Aform.frameworktext,1))) {
51         _alertString += "\n- " + _("Description missing");
52     }
53     if (_alertString.length==0) {
54         document.Aform.submit();
55     } else {
56         alertString2  = _("Form not submitted because of the following problem(s)");
57         alertString2 += "\n------------------------------------------------------------------------------------\n";
58         alertString2 += _alertString;
59         alert(alertString2);
60     }
61 }
62 </script>
63
64 <div id="doc3" class="yui-t2">
65    
66    <div id="bd">
67         <div id="yui-main">
68         <div class="yui-b"><div class="yui-g">
69
70 <!-- TMPL_IF NAME="add_form" -->
71     <h1><!-- TMPL_IF NAME="frameworkcode" -->Modify framework text<!-- TMPL_ELSE -->Add framework<!-- /TMPL_IF --></h1>
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="checked" value="0" />
75         <!-- TMPL_IF NAME="frameworkcode" -->
76             <p><label for="frameworkcode">Framework Code</label><input type="hidden" id="frameworkcode" name="frameworkcode" value="<!-- TMPL_VAR NAME="frameworkcode" -->" /><!-- TMPL_VAR NAME="frameworkcode" --></p>
77         <!-- TMPL_ELSE -->
78             <p><label for="frameworkcode">Framework Code</label><input type="text" id="frameworkcode" name="frameworkcode" size="4" maxlength="4" onblur="toUC(this)" /></p>
79         <!-- /TMPL_IF -->
80         <p><label for="description">Description</label>
81         <input type="text" name="frameworktext" size="40" maxlength="80" value="<!-- TMPL_VAR NAME="frameworktext" ESCAPE="HTML" -->" /></p>
82         <p>     <input type="button" value="Submit" class="submit" onclick="Check(this.form)" /></p>
83     </form>
84 <!-- /TMPL_IF -->
85
86 <!-- TMPL_IF NAME="delete_confirm" -->
87 <h3>Delete ramework for <!-- TMPL_VAR NAME="frameworktext" --> (<!-- TMPL_VAR NAME="frameworkcode" -->)?</h3>
88     <!-- TMPL_IF NAME="total" -->
89         <div class="error">This framework is used <!-- TMPL_VAR NAME="total" --> times
90     <!-- /TMPL_IF -->
91     <p>
92         <form class="inline" action="<!-- TMPL_VAR NAME="script_name" -->" method="post"><input type="hidden" name="op" value="delete_confirmed" /><input type="hidden" name="frameworkcode" value="<!-- TMPL_VAR NAME="frameworkcode" -->" /><input type="submit" value="Yes, Delete this Framework!" />
93         </form>
94         <form class="inline" action="<!-- TMPL_VAR NAME="script_name" -->" method="post"><input type="submit" value="No, Do not Delete!" /></form>
95     </p>
96 <!-- /TMPL_IF -->
97
98 <!-- TMPL_IF NAME="else" -->
99 <h1>Biblio framework</h1>
100 <p>Framework name, then go to MARC biblio to set MARC editor parameters</p>
101 <table>
102     <tr>
103         <th>Code</th>
104         <th>Description</th>
105         <th>&nbsp;</th>
106         <th>Edit</th>
107         <th>Delete</th>
108     </tr>
109     <tr>
110         <td>&nbsp;</td>
111         <td>Default framework</td>
112         <td><a href="marctagstructure.pl?frameworkcode=<!-- TMPL_VAR NAME="frameworkcode" -->">MARC structure</td>
113         <td>&nbsp;</td>
114         <td>&nbsp;</td>
115     </tr>
116     
117     <!-- TMPL_LOOP NAME="loop" -->
118         <tr>
119             <td><!-- TMPL_VAR name="frameworkcode" --></td>
120             <td><!-- TMPL_VAR name="frameworktext" --></td>
121             <td><a href="marctagstructure.pl?frameworkcode=<!-- TMPL_VAR name="frameworkcode" -->" >MARC structure</a></td>
122             <td><a href="<!-- TMPL_VAR name="script_name" -->?op=add_form&amp;frameworkcode=<!-- TMPL_VAR name="frameworkcode" escape="HTML" -->">Edit</a></td>
123             <td><a href="<!-- TMPL_VAR name="script_name" -->?op=delete_confirm&amp;frameworkcode=<!-- TMPL_VAR name="frameworkcode" escape="HTML" -->">Delete</a></td>
124         </tr>
125     <!-- /TMPL_LOOP -->
126 </table>
127 <form action="<!-- TMPL_VAR NAME="script_name" -->" method="post">
128     <input type="hidden" name="op" value="add_form" />
129     <input type="submit" value="Add framework" />
130     <td><!-- TMPL_IF NAME="previous" --><a href="<!-- TMPL_VAR NAME="previous" -->">&lt;&lt; Previous</a><!-- /TMPL_IF --></td>
131     <td><!-- TMPL_IF NAME="next" --><a href="<!-- TMPL_VAR NAME="next" -->">Next &gt;&gt;</a><!-- /TMPL_IF --></td>
132 </form>
133
134 <!-- /TMPL_IF -->
135 </div>
136 </div>
137 </div>
138
139 <!-- TMPL_INCLUDE NAME="mainmenu.inc" -->
140 <!-- TMPL_INCLUDE NAME="intranet-bottom.inc" -->