Cleanup on Serials. Markup corrections and cleanup, moving script blocks into header...
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / modules / serials / serials-collection.tmpl
1 <!-- TMPL_INCLUDE NAME="doc-head-open.inc" -->
2 <title>Koha &rsaquo; Serials</title>
3 <!-- TMPL_INCLUDE NAME="doc-head-close.inc" -->
4 <script language="JavaScript" type="text/javascript">
5 showlayer('<!-- TMPL_VAR NAME="yearmax"-->');
6
7 function showlayer(numlayer)
8 {
9         var yeardata=document.getElementsByName("yeardata");
10     for (i=0; i<yeardata.length; i++ ) {
11                 ong=yeardata[i].getAttribute('id');
12         if (numlayer==ong) {
13                         yeardata[i].setAttribute("class","content_visible");
14             var tabactive=document.getElementById('link'+numlayer);
15             tabactive.removeAttribute("class");
16             tabactive.setAttribute("class","tab_active");
17                 } else {
18                         yeardata[i].removeAttribute("class");
19             yeardata[i].setAttribute("class","content_hidden");
20             try {
21                 var tabactive=document.getElementById('link'+ong);
22                 tabactive.removeAttribute("class");
23                 tabactive.setAttribute("class","tab_inactive");
24             }
25             catch(e){};
26                 }
27         }
28 }
29 function addsubscriptionid()
30 {
31         var tab=new Array();
32     var serialids = document.edition.serialid;
33     for (i=0; i<serialids.length; i++){
34       if (serialids[i].checked == true){
35         var found=false;
36         for (var val in tab){
37           if (tab[val] == document.getElementsByName("subs")[i].getAttribute('val')){found = true;}
38         }
39         if (found == false){
40           tab=tab.concat((document.getElementsByName("subs")[i].getAttribute('val')));
41         }
42       }
43     }
44     var string="";
45     for (var val in tab){
46       string = string + tab[val] + ",";
47     }
48     string=string.substring(0,string.length -1);
49     document.edition.subscriptionid.value=string;
50 }
51 function popup(subscriptionid) {
52     newin=window.open('subscription-renew.pl?mode=popup&subscriptionid='+subscriptionid,'popup','width=500,height=400,toolbar=false,scrollbars=yes');
53 }
54 </script>
55 </head>
56 <body>
57 <!-- TMPL_INCLUDE NAME="header.inc" -->
58 <!--TMPL_INCLUDE NAME="menu-serials.inc" -->
59
60 <div id="doc3" class="yui-t2">
61    
62    <div id="bd">
63         <div id="yui-main">
64         <div class="yui-b"><div class="yui-g">
65
66
67 <!-- TMPL_UNLESS name="popup" -->
68
69         <h1>Serial Collection information for<br /> <em><!-- TMPL_VAR name="bibliotitle" --></em></h1>
70 <!-- /TMPL_UNLESS -->
71
72 <!--TMPL_IF Name="subscriptions"-->
73 <table>
74 <!--TMPL_IF Name="onesubscription"-->
75 <caption> Subscription Summary</caption>
76 <!--TMPL_ELSE-->
77 <caption> Subscription Summaries</caption>
78 <!--/TMPL_IF-->
79 <tr>
80   <th>Subs </th>
81   <th>Freq</th>
82   <th>Num pattern</th>
83   <th>Branch</th>
84   <th>Call Number</th>
85   <th>Notes</th>
86   <th>Renew</th>
87 </tr>
88 <!--TMPL_LOOP Name="subscriptions"-->
89         <tr>
90       <td><a href="subscription-detail.pl?subscriptionid=<!-- TMPL_VAR name="subscriptionid" -->">#<!-- TMPL_VAR name="subscriptionid" --></a> </td>
91       <td>         <!--TMPL_IF name="periodicity1" -->
92                         1/day
93                 <!-- /TMPL_IF -->
94                 <!--TMPL_IF name="periodicity2" -->
95                         1/week
96                 <!-- /TMPL_IF -->
97                 <!--TMPL_IF name="periodicity3" -->
98                         1/2 weeks
99                 <!-- /TMPL_IF -->
100                 <!--TMPL_IF name="periodicity4" -->
101                         1/3 weeks
102                 <!-- /TMPL_IF -->
103                 <!--TMPL_IF name="periodicity5" -->
104                         1/Month
105                 <!-- /TMPL_IF -->
106                 <!--TMPL_IF name="periodicity6" -->
107                         1/2 Months (6/year)
108                 <!-- /TMPL_IF -->
109                 <!--TMPL_IF name="periodicity7" -->
110                         1/quarter
111                 <!-- /TMPL_IF -->
112                 <!--TMPL_IF name="periodicity8" -->
113                         1/quarter
114                 <!-- /TMPL_IF -->
115                 <!--TMPL_IF name="periodicity9" -->
116                         2/year
117                 <!-- /TMPL_IF -->
118                 <!--TMPL_IF name="periodicity10" -->
119                         1/year
120                 <!-- /TMPL_IF -->
121                 <!--TMPL_IF name="periodicity11" -->
122                         1/2 years
123                 <!-- /TMPL_IF --></td>
124            <td>
125                 <!-- TMPL_IF name="numberpattern1" -->
126                     Number
127                 <!-- /TMPL_IF -->
128                 <!-- TMPL_IF name="numberpattern2" -->
129                     Volume, Number, Issue
130                 <!-- /TMPL_IF -->
131                 <!-- TMPL_IF name="numberpattern3" -->
132                     Volume, Number
133                 <!-- /TMPL_IF -->
134                 <!-- TMPL_IF name="numberpattern4" -->
135                     Volume, Issue
136                 <!-- /TMPL_IF -->
137                 <!-- TMPL_IF name="numberpattern5" -->
138                     Number, Issue
139                 <!-- /TMPL_IF -->
140                 <!-- TMPL_IF name="numberpattern6" -->
141                     Seasonal only
142                 <!-- /TMPL_IF -->
143                 <!-- TMPL_IF name="numberpattern7" -->
144                     None of the above
145                 <!-- /TMPL_IF --></td>
146             <td> <!-- TMPL_VAR name="branchcode" --></td>
147             <td> <!-- TMPL_VAR name="callnumber" --></td>
148         <td> <!-- TMPL_VAR name="notes" -->        <!--TMPL_IF name="subscriptionexpired"--><br /><span class="problem"> Subscription Expired</span>
149         <!--/TMPL_IF-->
150         </td>
151         <!--TMPL_IF name="abouttoexpire"--><td class="problem"> <a onclick="popup(<!--TMPL_VAR Name="subscriptionid"-->)">Renew</a></td>
152         <!--TMPL_ELSE-->
153         <!--TMPL_IF name="subscriptionexpired"--><td class="problem"> <a onclick="popup(<!--TMPL_VAR Name="subscriptionid"-->)">Renew</a></td>
154         <!--TMPL_ELSE-->
155         <td> &nbsp;</td>
156         <!--/TMPL_IF-->
157         <!--/TMPL_IF-->
158
159       </tr>
160 <!--/TMPL_LOOP -->
161 <!--TMPL_IF Name="subscr"-->
162 <tr ><td colspan="7">  <a href="serials-collection.pl?biblionumber=<!--TMPL_VAR Name="biblionumber" -->">See any subscription attached to this biblio</a></td>
163 </tr>
164 <!--/TMPL_IF-->
165 </table>
166 <!--/TMPL_IF -->
167     <div class="tabsubs">
168     <!-- TMPL_LOOP NAME="years" -->
169         <!-- TMPL_IF NAME="year" -->
170         <!-- TMPL_IF NAME="first" -->
171             <a  id="link<!-- TMPL_VAR NAME="year" -->" class="tab_active" href="javascript:showlayer('<!-- TMPL_VAR NAME="year" -->')"><!-- TMPL_VAR NAME="year" --></a>
172         <!-- TMPL_ELSE -->
173             <a  id="link<!-- TMPL_VAR NAME="year" -->" class="tab_inactive" href="javascript:showlayer('<!-- TMPL_VAR NAME="year" -->')"><!-- TMPL_VAR NAME="year" --></a>
174         <!-- /TMPL_IF -->
175         <!-- /TMPL_IF -->
176     <!-- /TMPL_LOOP -->
177     </div>
178
179 <form name="edition" action="serials-edit.pl">
180  <!-- TMPL_LOOP NAME="years" -->
181  <!--TMPL_IF Name="first" -->
182     <div name="yeardata" id="<!-- TMPL_VAR NAME="year" -->" class="content_visible" >
183  <!--TMPL_ELSE -->
184     <div name="yeardata" id="<!-- TMPL_VAR NAME="year" -->" class="content_hidden">
185  <!--/TMPL_IF -->
186         <table width="400px">
187             <tr>
188 <!--TMPL_UNLESS Name="onesubscription"-->
189                 <th> # Subs.
190                 </th>
191 <!--/TMPL_UNLESS-->
192                 <th>Date published
193                 </th>
194                 <th>Date received
195                 </th>
196                 <th> Number
197                 </th>
198                 <th> Status
199                 </th>
200                 <th> Notes
201                 </th>
202                 <th>branch
203                 </th>
204                 <th>Edit
205                 </th>
206             </tr>
207       <!-- TMPL_LOOP Name="serials" -->
208             <tr name="branch <!--TMPL_VAR Name="branchcode"-->">
209 <!--TMPL_UNLESS Name="onesubscription"-->
210                  <td><a href="serials-collection.pl?subscriptionid=<!--TMPL_VAR Name="subscriptionid"-->"><!--TMPL_VAR Name="subscriptionid"--></a></td>
211 <!--/TMPL_UNLESS-->
212                 <td>
213                     <!-- TMPL_VAR Name="publisheddate" -->
214                 </td>
215                 <td>
216                     <!-- TMPL_VAR Name="planneddate" -->
217                 </td>
218                 <td>
219                     <!-- TMPL_VAR Name="serialseq" -->
220                 </td>
221                 <td>
222                     <!-- TMPL_IF Name="status1" -->Waited<!-- /TMPL_IF -->
223                     <!-- TMPL_IF Name="status2" -->Arrived<!-- /TMPL_IF -->
224                     <!-- TMPL_IF Name="status3" -->Late<!-- /TMPL_IF -->
225                     <!-- TMPL_IF Name="status4" -->Missing<!-- /TMPL_IF -->
226                     <!-- TMPL_IF Name="status7" -->Claimed<!-- /TMPL_IF -->
227                 </td>
228                 <td>
229                     <!-- TMPL_VAR Name="notes" -->
230                 </td>
231                 <td>
232                     <!-- TMPL_VAR Name="branchcode" -->
233                 </td>
234                 <td>
235                   <div visibility="hidden" name="subs" val="<!--TMPL_VAR Name="subscriptionid"-->"></div>
236                   <!--TMPL_IF Name="subscriptionexpired"-->
237                   <input type="checkbox" name="serialid" value="<!--TMPL_VAR Name="serialid"-->" disabled="disabled" />
238                   <!--TMPL_ELSE-->
239                     <!--TMPL_IF Name="status1"-->
240                     <input type="checkbox" name="serialid" checked value="<!--TMPL_VAR Name="serialid"-->" />
241                     <!--TMPL_ELSE -->
242                     <!--TMPL_IF Name="status3"-->
243                     <input type="checkbox" name="serialid" checked value="<!--TMPL_VAR Name="serialid"-->" />
244                     <!--TMPL_ELSE -->
245                       <!--TMPL_IF Name="status4"-->
246                       <input type="checkbox" name="serialid" checked value="<!--TMPL_VAR Name="serialid"-->" />
247                       <!--TMPL_ELSE -->
248                       <input type="checkbox" name="serialid" value="<!--TMPL_VAR Name="serialid"-->" />
249                       <!--/TMPL_IF-->           
250                     <!--/TMPL_IF-->           
251                     <!--/TMPL_IF-->           
252                   <!--/TMPL_IF -->
253                 </td>
254             </tr>
255       <!-- /TMPL_LOOP -->
256         </table>
257       <p><input type="submit" value="Edit serials" /></p>
258     </div>
259     <!--/TMPL_LOOP -->
260   <input type="hidden" name="subscriptionid" value="<!--TMPL_VAR Name="subscriptionidlist"-->" />
261
262 </form>
263
264 </div>
265 </div>
266 </div>
267
268 <!-- TMPL_INCLUDE NAME="mainmenu.inc" -->
269 <!-- TMPL_INCLUDE NAME="intranet-bottom.inc" -->
270