Merge branch 'bug_9591' into 3.14-master
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / modules / circ / circulation.tt
1 [% USE KohaDates %]
2 [% USE KohaAuthorisedValues %]
3 [% INCLUDE 'doc-head-open.inc' %]
4 [% SET destination = "circ" %]
5 <title>Koha &rsaquo; Circulation
6 [% IF borrowernumber %]
7   &rsaquo; Checking out to [% INCLUDE 'patron-title.inc' invert_name = 1 %]
8 [% END %]
9 </title>
10 [% INCLUDE 'doc-head-close.inc' %]
11 [% INCLUDE 'calendar.inc' %]
12 [% IF ( UseTablesortForCirc ) %]<script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.tablesorter.min.js"></script>[% END %]
13 <script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.checkboxes.min.js"></script>
14 <script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery-ui-timepicker-addon.js"></script>
15 <script type="text/javascript">
16 //<![CDATA[
17 [% IF ( borrowernumber ) %]if($.cookie("holdfor") != [% borrowernumber %]){ $.cookie("holdfor",null, { path: "/", expires: 0 }); }[% ELSE %]$.cookie("holdfor",null, { path: "/", expires: 0 });[% END %]
18 [% IF ( UseTablesortForCirc ) %]$.tablesorter.addParser({
19     id: 'articles',
20     is: function(s) {return false;  },
21     format: function(s) { return s.toLowerCase().replace(/^(the|an|a) /,''); },
22     type: 'text'
23 });[% END %]
24 [% UNLESS ( borrowernumber ) %][% UNLESS ( CGIselectborrower ) %]window.onload=function(){ $('#findborrower').focus(); };[% END %][% END %]
25          $(document).ready(function() {
26
27         $('#patronlists').tabs();
28                 [% IF ( UseTablesortForCirc ) %]$.tablesorter.defaults.widgets = ['zebra'];
29                 $("#issuest").tablesorter({[% IF ( dateformat_metric ) %]
30                 dateFormat: 'uk',[% END %]
31                 headers: { 1: { sorter: 'articles' },6: { sorter: false },7:{sorter:false},8:{sorter:false},9:{sorter:false}}
32                 });
33                 $("#relissuest").tablesorter({[% IF ( dateformat_metric ) %]
34                 dateFormat: 'uk',[% END %]
35                 headers: { 1: { sorter: 'articles' },6: { sorter: false },7:{sorter:false},8:{sorter:false},9:{sorter:false}}
36                 });
37
38                 //FIXME: Sorting does not work when there are previous checkouts only
39                 // (It works fine when there are only checkouts of the day, or both previous and today checkouts)
40                 $("#issuest").bind("sortEnd",function() {
41                 $("#previous").parents("tr").remove();  // 'previous checkouts' header chokes table sorter
42             });
43                 $("#relissuest").bind("sortEnd",function() {
44                     $("#relprevious").parents("tr").remove();  // 'previous checkouts' header chokes table sorter
45                 });
46                 $("#holdst").tablesorter({[% IF ( dateformat_metric ) %]
47                 dateFormat: 'uk',[% END %]
48                         sortList: [[0,0]],
49                         headers: { 1: { sorter: 'articles' },5: { sorter: false }}
50                 });[% END %]
51         [% IF ( AllowRenewalLimitOverride ) %]
52         $( '#override_limit' ).click( function () {
53             if ( this.checked ) {
54                 $( '.renewals-allowed' ).show(); $( '.renewals-disabled' ).hide();
55             } else {
56                 $( '.renewals-allowed' ).hide(); $( '.renewals-disabled' ).show();
57             }
58         } ).attr( 'checked', false );
59         [% END %][% IF ( CircAutoPrintQuickSlip ) %]
60         // listen submit to trigger qslip on empty checkout
61         $('#mainform').bind('submit',function() {
62           if ($('#barcode').val() == '') {
63             return printx_window('qslip'); }
64         });[% END %]
65
66
67 var allcheckboxes = $(".checkboxed");
68         $("#renew_all").click(function(){
69                 $(allcheckboxes).checkCheckboxes(":input[name*=items]"); 
70                 $(allcheckboxes).unCheckCheckboxes(":input[name*=barcodes]");
71         });
72         $("#CheckAllitems").click(function(){
73                 $(allcheckboxes).checkCheckboxes(":input[name*=items]");
74                 $(allcheckboxes).unCheckCheckboxes(":input[name*=barcodes]"); return false;
75         });
76     $("#CheckNoitems").click(function(){
77                 $(allcheckboxes).unCheckCheckboxes(":input[name*=items]"); return false;
78         });
79         $("#CheckAllreturns").click(function(){
80                 $(allcheckboxes).checkCheckboxes(":input[name*=barcodes]");
81                 $(allcheckboxes).unCheckCheckboxes(":input[name*=items]"); return false;
82         });
83     $("#CheckNoreturns" ).click(function(){
84                 $(allcheckboxes).unCheckCheckboxes(":input[name*=barcodes]"); return false;
85         });
86
87     $("#CheckAllexports").click(function(){
88         $(".checkboxed").checkCheckboxes(":input[name*=biblionumbers]");
89         $(".checkboxed").unCheckCheckboxes(":input[name*=items]");
90         return false;
91     });
92     $("#CheckNoexports").click(function(){
93         $(".checkboxed").unCheckCheckboxes(":input[name*=biblionumbers]");
94         return false;
95     });
96
97     $("#relrenew_all").click(function(){
98         $(allcheckboxes).checkCheckboxes(":input[name*=items]");
99         $(allcheckboxes).unCheckCheckboxes(":input[name*=barcodes]");
100     });
101     $("#relCheckAllitems").click(function(){
102         $(allcheckboxes).checkCheckboxes(":input[name*=items]");
103         $(allcheckboxes).unCheckCheckboxes(":input[name*=barcodes]"); return false;
104     });
105     $("#relCheckNoitems").click(function(){
106         $(allcheckboxes).unCheckCheckboxes(":input[name*=items]"); return false;
107     });
108     $("#relCheckAllreturns").click(function(){
109         $(allcheckboxes).checkCheckboxes(":input[name*=barcodes]");
110         $(allcheckboxes).unCheckCheckboxes(":input[name*=items]"); return false;
111     });
112     $("#relCheckNoreturns").click(function(){
113         $(allcheckboxes).unCheckCheckboxes(":input[name*=barcodes]"); return false;
114     });
115
116     [% IF ( CAN_user_circulate_override_renewals ) %]
117     [% IF ( AllowRenewalLimitOverride ) %]
118     $( '#override_limit' ).click( function () {
119         if ( this.checked ) {
120            $( '.renewals-allowed' ).show(); $( '.renewals-disabled' ).hide();
121         } else {
122            $( '.renewals-allowed' ).hide(); $( '.renewals-disabled' ).show();
123         }
124     } ).attr( 'checked', false );
125     [% END %]
126     [% END %]
127     // Clicking the table cell checks the checkbox inside it
128         $("td").click(function(e){
129                 if(e.target.tagName.toLowerCase() == 'td'){
130            $(this).find("input:checkbox:visible").each( function() {
131                 if($(this).attr("checked")){
132                     $(this).removeAttr("checked");
133                 } else {
134                     $(this).attr("checked","checked");
135                     radioCheckBox($(this));
136                 }
137            });
138         }
139         });
140     // prevent adjacent checkboxes from being checked simultaneously
141     function radioCheckBox(box){
142             box.parents("td").siblings().find("input:checkbox:visible").each(function(){
143                 if($(this).attr("checked")){
144                     $(this).removeAttr("checked");
145                 }
146              });
147      }
148
149         $("#messages ul").after("<a href=\"#\" id=\"addmessage\">"+_("Add a new message")+"</a>");
150         $("#borrower_messages .cancel").click(function(){
151                 $("#add_message_form").hide();
152         $("#addmessage").show();
153         });
154         $("#addmessage").click(function (){
155         $(this).hide();
156                 $("#add_message_form").show();
157          });
158
159     $("input.radio").click(function(){
160         radioCheckBox($(this));
161     });
162
163     $("#newduedate").datetimepicker({
164         minDate: 1, // require that renewal date is after today
165         hour: 23,
166         minute: 59
167     });
168     $("#duedatespec").datetimepicker({
169         onClose: function(dateText, inst) { $("#barcode").focus(); },
170         hour: 23,
171         minute: 59
172     });
173     $("#export_submit").click(function(){
174         var export_format = $("#export_formats").val();
175         export_checkouts(export_format);
176         return false;
177     })
178  });
179
180 function export_checkouts(format) {
181     if ($("input:checkbox[name='biblionumbers'][checked]").length < 1){
182         alert(_("You must select a checkout to export"));
183         return;
184     }
185
186     $("input:checkbox[name='biblionumbers']").each( function(){
187         var input_item = $(this).siblings("input:checkbox");
188         if ( $(this).is(":checked") ) {
189             $(input_item).attr("checked", "checked");
190         } else {
191             $(input_item).attr("checked", "");
192         }
193     } );
194
195     if (format == 'iso2709_995') {
196         format = 'iso2709';
197         $("#dont_export_item").val(0);
198     } else if (format == 'iso2709') {
199         $("#dont_export_item").val(1);
200     } else {
201         [% UNLESS ( export_with_csv_profile ) %]
202             alert(_("You must define a csv profile for export (in tools>CSV export profiles) and fill the ExportWithCsvProfile system preference"));
203             return false;
204         [% END %]
205     }
206     document.issues.action="/cgi-bin/koha/tools/export.pl";
207     document.getElementById("export_format").value = format;
208     document.issues.submit();
209
210     /* Reset form action to its initial value */
211     document.issues.action="/cgi-bin/koha/reserve/renewscript.pl";
212
213 };
214
215 function validate1(date) {
216     var today = new Date();
217     if ( date < today ) {
218         return true;
219      } else {
220         return false;
221      }
222 };
223 //]]>
224 </script>
225 </head>
226 <body id="circ_circulation" class="circ">
227
228 [% INCLUDE 'header.inc' %]
229 [% INCLUDE 'circ-search.inc' %]
230
231 <div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> &rsaquo; <a href="/cgi-bin/koha/circ/circulation-home.pl">Circulation</a> &rsaquo;
232 [% IF ( borrowernumber ) %]
233     <a href="/cgi-bin/koha/circ/circulation.pl">Checkouts</a> &rsaquo; [% INCLUDE 'patron-title.inc' %]
234 [% ELSE %]
235     <strong>Checkouts</strong>
236 [% END %]
237 </div>
238 [% IF ( CGIselectborrower ) %]
239 <div id="doc" class="yui-t7">
240
241    <div id="bd">
242         <div id="yui-main">
243         <div class="yui-g">
244 [% ELSE %]
245 <div id="doc3" class="yui-t2">
246
247    <div id="bd">
248         <div id="yui-main">
249         <div class="yui-b">
250 [% END %]
251
252 [% IF ( borrowernumber ) %]
253 [% INCLUDE 'members-toolbar.inc' %]
254 [% END %]
255
256 <!--  INITIAL BLOC : PARAMETERS & BORROWER INFO -->
257 <div style="display: none;" id="add_message_form">
258 <form method="post" action="/cgi-bin/koha/circ/add_message.pl" id="message_form" name="message_f">
259 <fieldset id="borrower_messages" class="brief">
260 <legend>Leave a message</legend>
261         <ol>
262     <li>
263             <label for="message_type">Add a message for:</label>
264           <select name="message_type" id="message_type">
265             <option value="L">Other librarians</option>
266             <option value="B">[% firstname %]</option>
267         </select>
268     </li>
269     [% IF ( canned_bor_notes_loop ) %]
270         <li>
271                 <label for="type">Predefined notes: </label>
272                 <select name="type" id="type" onchange="this.form.borrower_message.value=this.options[this.selectedIndex].value;">
273                     <option value="">Select note</option>
274                     [% FOREACH canned_bor_notes_loo IN canned_bor_notes_loop %]
275                     <option value="[% canned_bor_notes_loo.lib %]">[% canned_bor_notes_loo.lib %]</option>
276                     [% END %]
277                 </select>
278         </li>
279     [% END %]
280     <li>
281         <textarea rows="3" cols="60" name="borrower_message" id="borrower_message" ></textarea>
282     </li>
283         </ol>
284     <fieldset class="action">
285         <input type="submit" value="Save" /> <a href="#" class="cancel">Cancel</a>
286     </fieldset>
287
288         <input type="hidden" name="borrowernumber" value="[% borrowernumber %]" />
289         <input type="hidden" name="branchcode" value="[% branch %]" />
290 </fieldset>
291 </form>
292 </div>
293
294 [% IF ( was_renewed ) %]<div class="dialog message">Patron's account has been renewed until [% expiry %]</div>[% END %]
295
296 [% IF additional_materials %]
297     <div id="materials" class="dialog message">Note about the accompanying materials: <br />
298     [% additional_materials %]
299     </div>
300 [% END %]
301
302 [% IF ( alert.ITEM_LOST ) %]
303     <div class="dialog message">This item has been lost with a status of "[% alert.ITEM_LOST %]".</div>
304 [% END %]
305
306 [% IF ( alert.OTHER_CHARGES ) %]
307     <div class="dialog message">The patron has unpaid charges for reserves, rentals etc of [% alert.OTHER_CHARGES %]</div>
308 [% END %]
309
310 [% IF ( NEEDSCONFIRMATION ) %]
311 <div class="yui-g">
312
313 <div id="circ_needsconfirmation" class="dialog alert">
314 <h3>Please confirm checkout</h3>
315
316 <ul>
317 [%IF ( AGE_RESTRICTION ) %]
318     <li>Age restriction [% AGE_RESTRICTION %]. Check out anyway?</li>
319 [% END %]
320
321 [% IF ( DEBT ) %]
322     <li>The patron has a debt of [% DEBT %]</li>
323 [% END %]
324
325 [% IF ( RENEW_ISSUE ) %]
326     <li>Item <i>[% getTitleMessageIteminfo %]</i> ([% getBarcodeMessageIteminfo %]) is currently checked out to this patron.  Renew?</li>
327 [% END %]
328
329 [% IF ( RESERVE_WAITING ) %]
330     <li>Item <i>[% getTitleMessageIteminfo %]</i> ([% getBarcodeMessageIteminfo %]) has been waiting for <a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% resborrowernumber %]">[% resfirstname %] [% ressurname %]</a> ([% rescardnumber %]) at [% resbranchname %] since [% reswaitingdate %]</li>
331 [% END %]
332
333 [% IF ( RESERVED ) %]
334     <li>Item <i>[% getTitleMessageIteminfo %]</i> ([% getBarcodeMessageIteminfo %]) has been on hold for <a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% resborrowernumber %]">[% resfirstname %] [% ressurname %]</a> ([% rescardnumber %]) at [% resbranchname %] since [% resreservedate %]</li>
335 [% END %]
336
337 [% IF ( ISSUED_TO_ANOTHER ) %]
338     <li>Item <i>[% getTitleMessageIteminfo %]</i> ([% getBarcodeMessageIteminfo %]) is checked out to <a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% issued_borrowernumber %]">[% issued_firstname %] [% issued_surname %]</a> ([% issued_cardnumber %]). Check in and check out?</li>
339 [% END %]
340
341 [% IF ( TOO_MANY ) %]
342     <li>Too many checked out. [% current_loan_count %] checked out, only [% max_loans_allowed %] are allowed.</li>
343 [% END %]
344
345 [% IF ( BORRNOTSAMEBRANCH ) %]
346     <li>This patrons is from a different library ([% BORRNOTSAMEBRANCH %])</li>
347 [% END %]
348
349 [% IF ( PATRON_CANT ) %]
350     <li>This patron can't check out this item per library circulation policy</li>
351 [% END %]
352
353 [% IF ( NOT_FOR_LOAN_FORCING ) %]
354     <li>
355     [% IF ( itemtype_notforloan ) %]
356         Item type is normally not for loan.
357     [% ELSIF ( item_notforloan ) %]
358         [% item_notforloan_lib = KohaAuthorisedValues.GetByCode( authvalcode_notforloan, item_notforloan, 0 ) %]
359         Item is normally not for loan [% IF (item_notforloan_lib) %]([% item_notforloan_lib %])[% END %].
360     [% END %]
361         Check out anyway?
362     </li>
363 [% END %]
364
365 [% IF ( USERBLOCKEDOVERDUE ) %]
366     <li>Patron has [% USERBLOCKEDOVERDUE %] overdue item(s).  Check out anyway?</li>
367 [% END %]
368
369 [% IF ( ITEM_LOST ) %]
370     <li>This item has been lost with a status of "[% ITEM_LOST %]". Check out anyway?</li>
371 [% END %]
372
373 [% IF  HIGHHOLDS %]
374         <li>High demand item. Loan period shortened to [% HIGHHOLDS.duration %] days (due [% HIGHHOLDS.returndate %]). Check out anyway?</li>
375 [% END %]
376 </ul>
377
378 [% IF HIGHHOLDS %]
379         <script language="JavaScript" type="text/javascript">
380         $(document).ready(function() {
381                 $("input[name=duedatespec]:hidden").val('[% HIGHHOLDS.returndate %]');
382         });
383         </script>
384 [% END %]
385 <form method="post" action="/cgi-bin/koha/circ/circulation.pl" autocomplete="off">
386
387 [% IF ( RESERVED ) %]
388     <p>
389     <input type="checkbox" id="cancelreserve" name="cancelreserve" value="cancel" />
390     <label for="cancelreserve">Cancel hold</label>
391     </p>
392 [% END %]
393
394 [% IF ( RESERVE_WAITING ) %]
395 <p>
396     <label for="cancelreserve">Cancel hold</label>
397     <input type="radio" value="cancel" name="cancelreserve" id="cancelreserve" /><br />
398     <label for="revertreserve">Revert waiting status</label>
399     <input type="radio" value="revert" name="cancelreserve" id="revertreserve" checked="checked"/>
400 </p>
401 [% END %]
402
403     <input type="hidden" name="barcode" value="[% barcode |html %]" />
404     <input type="hidden" name="borrowernumber" value="[% borrowernumber %]" />
405     <input type="hidden" name="issueconfirmed" value="1" />
406     [% IF ( DEBT ) %]<input type="hidden" name="debt_confirmed" value="1" />[% END %]
407     [% IF ( INVALID_DATE ) %]
408     <p>
409     <input type="text" size="13" id="duedatespec" name="duedatespec" readonly="readonly" value="[% duedatespec %]" />
410     <label for="duedatespec">Due date</label>
411     </p>
412     [% ELSE %]
413     <input type="hidden" name="duedatespec" value="[% duedatespec %]" />
414     [% END %]
415     <input type="hidden" name="stickyduedate" value="[% stickyduedate %]" />
416     <input type="hidden" name="branch" value="[% branch %]" />
417     [% IF ( RENEW_ISSUE ) %]
418     <input type="submit" class="approve" value="Yes, Renew (Y)" accesskey="y" />
419     [% ELSE %]
420     <input type="submit" class="approve" value="Yes, Check Out (Y)" accesskey="y" />
421     [% END %]
422 </form>
423
424 <form method="get" action="/cgi-bin/koha/circ/circulation.pl">
425     <input type="hidden" name="borrowernumber" value="[% borrowernumber %]" />
426     <input type="hidden" name="duedatespec" value="[% duedatespec %]" />
427     <input type="hidden" name="stickyduedate" value="[% stickyduedate %]" />
428     [% IF ( RENEW_ISSUE ) %]
429     <input type="submit" class="deny" value="No, Don't Renew (N)" accesskey="n" />
430     [% ELSE %]
431     <input type="submit" class="deny" value="No, Don't Check Out (N)" accesskey="n" />
432     [% END %]
433 </form>
434
435 </div></div>
436 [% END %] <!-- NEEDSCONFIRMATION -->
437
438         [% IF ( IMPOSSIBLE ) %]
439
440 [% IF ( soundon ) %]
441 <audio src="/intranet-tmpl/prog/sound/critical.ogg" autoplay="autoplay" autobuffer="autobuffer"></audio>
442 [% END %]        
443
444 <div class="yui-g">
445 <div id="circ_impossible" class="dialog alert">
446 <!-- RESULT OF ISSUING REQUEST -->
447         <ul>
448         [% IF ( STATS ) %]
449             <li>Local use recorded</li>
450         [% END %]
451
452         [% IF ( INVALID_DATE ) %]
453             <li>The due date &quot;[% INVALID_DATE %]&quot; is invalid</li>
454         [% END %]
455
456         [% IF ( UNKNOWN_BARCODE ) %]
457             <li>The barcode was not found [% barcode |html %]</li>
458             [% IF ( fast_cataloging ) %]
459                 [% IF ( CAN_user_editcatalogue_fast_cataloging ) %]
460             <a href="/cgi-bin/koha/cataloguing/addbiblio.pl?frameworkcode=FA&amp;barcode=[% barcode |uri %]&amp;circborrowernumber=[% borrowernumber %]&amp;branch=[% branch %]&amp;duedatespec=[% duedatespec %]&amp;stickyduedate=[% stickyduedate %]">Fast cataloging</a>
461                 [% END %]
462             [% END %]
463         [% END %]
464
465         [% IF ( NOT_FOR_LOAN ) %]
466             <li>
467             [% IF ( itemtype_notforloan ) %]
468                 Item type not for loan.
469             [% ELSIF ( item_notforloan ) %]
470                 [% item_notforloan_lib = KohaAuthorisedValues.GetByCode( authvalcode_notforloan, item_notforloan, 0 ) %]
471                 Item not for loan [% IF (item_notforloan_lib) %]([% item_notforloan_lib %])[% END %].
472             [% END %]
473             </li>
474         [% END %]
475
476         [% IF ( WTHDRAWN ) %]
477             <li>Item has been withdrawn</li>
478         [% END %]
479
480         [% IF ( RESTRICTED ) %]
481             <li>Item is restricted</li>
482         [% END %]
483
484         [% IF ( GNA ) %]
485             <li>Patron's address is in doubt</li>
486         [% END %]
487
488         [% IF ( CARD_LOST ) %]
489             <li>Patron's card is lost</li>
490         [% END %]
491
492         [% IF ( DEBARRED ) %]
493             <li>Patron is restricted</li>
494         [% END %]
495
496         [% IF ( NO_MORE_RENEWALS ) %]
497             <li>No more renewals possible</li>
498         [% END %]
499
500         [%IF ( AGE_RESTRICTION ) %]
501             <li>Age restriction [% AGE_RESTRICTION %].</li>
502         [% END %]
503
504         [% IF ( EXPIRED ) %]
505             <li>Patron's card is expired</li>
506         [% END %]
507
508         [% IF ( ITEMNOTSAMEBRANCH ) %]
509             <li>This item belongs to [% itemhomebranch %] and cannot be issued from this location.</li>
510         [% END %]
511
512         [% IF ( USERBLOCKEDREMAINING ) %]
513             <li>Patron has had overdue items and is blocked for [% USERBLOCKEDREMAINING %] day(s).</li>
514         [% END %]
515         
516             [% IF ( USERBLOCKEDOVERDUE ) %]
517             <li>Checkouts are BLOCKED because patron has overdue items</li>
518         [% END %]
519         </ul>
520
521 </div></div>
522 [% ELSE %]
523 [% IF ( soundon ) %]
524 <audio src="/intranet-tmpl/prog/sound/beep.ogg" autoplay="autoplay" autobuffer="autobuffer"></audio>
525 [% END %]
526     [% END %] <!-- /impossible -->
527
528 [% IF ( issued ) %]
529 <p>Item checked out</p>
530 [% END %]
531
532 [% IF ( message ) %]
533 [% INCLUDE 'patron-toolbar.inc' %]
534 <h4>
535 No patron matched <span class="ex">[% message %]</span>
536 </h4>
537 [% END %]
538
539
540 [% IF ( CGIselectborrower ) %]
541 [% INCLUDE 'patron-toolbar.inc' %]
542
543 <form method="post" action="/cgi-bin/koha/circ/circulation.pl" id="mainform" name="mainform" autocomplete="off">
544 <fieldset id="circ_circulation_selectborrower" class="brief">
545     <legend>Patron selection</legend>
546
547     <input type="hidden" name="branch" value="[% branch %]" />
548     <input type="hidden" name="printer" value="[% printer %]" />
549     <input type="hidden" name="duedatespec" value="[% duedatespec %]" />
550     <input type="hidden" name="stickyduedate" value="[% stickyduedate %]" />
551
552 <ol>    <li>
553     <label for="borrowernumber">Select a patron: </label>
554     [% CGIselectborrower %]
555     </li>
556 </ol>
557 <p><input type="submit" value="Select" /></p>
558 </fieldset>
559 </form>
560 [% ELSE %] <!-- CGIselectborrower -->
561
562 <!-- BARCODE ENTRY -->
563
564 [% IF ( borrowernumber ) %]
565 <div class="yui-g">
566 [% UNLESS ( noissues ) %]
567 [% IF ( flagged ) %]
568 <div class="yui-u first">
569 [% ELSE %]
570 <div>
571
572 [% END %]
573
574
575 <form method="post" action="/cgi-bin/koha/circ/circulation.pl" id="mainform" name="mainform" autocomplete="off">
576 <fieldset id="circ_circulation_issue">
577     [% IF ( DisplayClearScreenButton ) %]
578         <span id="clearscreen"><a href="/cgi-bin/koha/circ/circulation.pl" title="Clear screen">x</a></span>
579     [% END %]
580
581     <label for="barcode">Checking out to [% INCLUDE 'patron-title.inc' %]</label>
582
583         <div class="hint">Enter item barcode:</div>
584
585     [% IF ( NEEDSCONFIRMATION ) %]
586             <input type="text" name="barcode" id="barcode" class="barcode focus" size="14" disabled="disabled" />
587     [% ELSE %]
588             <input type="text" name="barcode" id="barcode" class="barcode focus" size="14" />
589     [% END %]
590     <input type="submit" value="Check Out" />
591
592     [% IF ( SpecifyDueDate ) %]<div class="date-select">
593         <div class="hint">Specify due date [% INCLUDE 'date-format.inc' %]: </div>
594         [% IF ( duedatespec ) %]<input type="text" size="13" id="duedatespec" name="duedatespec" value="[% duedatespec %]" readonly="readonly" />[% ELSE %]<input type="text" size="13" id="duedatespec" name="duedatespec" value="" readonly="readonly" />
595 [% END %]
596           <label for="stickyduedate"> Remember for session:</label>
597 [% IF ( stickyduedate ) %]
598 <input type="checkbox" id="stickyduedate" onclick="this.form.barcode.focus();" name="stickyduedate" checked="checked" />
599 [% ELSE %]
600 <input type="checkbox" id="stickyduedate" onclick="this.form.barcode.focus();" name="stickyduedate" />
601 [% END %]
602           <input type="button" class="action" id="cleardate" value="Clear" name="cleardate" onclick="this.checked = false; this.form.duedatespec.value = ''; this.form.stickyduedate.checked = false; this.form.barcode.focus(); return false;" />
603 </div>[% END %]
604           <input type="hidden" name="borrowernumber" id="borrowernumber" value="[% borrowernumber %]" />
605           <input type="hidden" name="branch" value="[% branch %]" />
606           <input type="hidden" name="printer" value="[% printer %]" />
607           <input type="hidden" name="print" value="maybe" />
608           <input type="hidden" name="debt_confirmed" value="[% debt_confirmed %]" />
609                 [% IF ( CHARGES ) %]
610                         <input type="hidden" name="charges" value="yes" />
611                         <input type="hidden" name="oldamount" value="[% amountold %]" />
612                 [% END %]
613 </fieldset>
614 </form></div>[% END %]<!-- /unless noissues -->
615
616 [% IF ( noissues ) %]<div>[% ELSE %]<div class="yui-u">[% END %]
617
618     [% IF ( flagged ) %]
619                 [% IF ( noissues ) %]
620                 <h4>Checking out to [% INCLUDE 'patron-title.inc' %]</h4>
621         <div id="circmessages" class="circmessage warning">
622                 [% ELSE %]
623         <div id="circmessages" class="circmessage attention">
624                 [% END %]
625
626                 <h3>[% IF ( noissues ) %]
627                         Cannot check out!
628                 [% ELSE %]Attention:[% END %]</h3>
629                 <ul>
630
631                         [% IF ( warndeparture ) %]
632                         <li><span class="circ-hlt">Expiration:</span> Patron's card will expire soon.
633                         Patron's card expires on [% expiry %] <a href="/cgi-bin/koha/members/setstatus.pl?borrowernumber=[% borrowernumber %]&amp;cardnumber=[% cardnumber %]&amp;destination=circ&amp;reregistration=y">Renew</a> or <a href="/cgi-bin/koha/members/memberentry.pl?op=modify&amp;destination=circ&amp;borrowernumber=[% borrowernumber %]&amp;categorycode=[% categorycode %]">Edit Details</a>
634
635                         </li>
636                         [% END %]
637
638                         [% IF ( returnbeforeexpiry ) %]
639                          <li><span class="circ-hlt">Set due date to expiry:</span> You have the ReturnBeforeExpiry system preference enabled this means if the
640                          expiry date is before the date due, the date due will be set to the expiry date
641                          </li>
642                         [% END %]
643
644                         [% IF ( expired ) %]
645                         <li><span class="circ-hlt">Expiration:</span> Patron's card has expired.
646                         [% IF ( expiry ) %]Patron's card expired on [% expiry %][% END %] <a href="/cgi-bin/koha/members/setstatus.pl?borrowernumber=[% borrowernumber %]&amp;cardnumber=[% cardnumber %]&amp;destination=circ&amp;reregistration=y">Renew</a> or <a href="/cgi-bin/koha/members/memberentry.pl?op=modify&amp;destination=circ&amp;borrowernumber=[% borrowernumber %]&amp;categorycode=[% categorycode %]">Edit Details</a>
647
648                         </li>
649                         [% END %]
650
651             [% IF ( gna ) %]
652                         <li class="blocker"><span class="circ-hlt">Address:</span> Patron's address in doubt</li>
653                         [% END %]
654
655             [% IF ( lost ) %]
656                         <li class="blocker"><span class="circ-hlt">Lost: </span>Patron's card is lost</li>
657                         [% END %]
658
659             [% IF ( userdebarred ) %]
660                <li class="blocker">
661                <span class="circ-hlt"> Restricted:</span> Patron's account is restricted [% IF (userdebarreddate ) %] until [% userdebarreddate %] [% END %] [% IF (debarredcomment ) %] with the comment "[% debarredcomment %]"[% END %]
662                <form class="inline compact" action="/cgi-bin/koha/members/setstatus.pl" method="post">
663                         <input type="hidden" name="borrowernumber" value="[% borrowernumber %]" />
664                         <input type="hidden" name="destination" value="circ" />
665                         <input type="hidden" name="cardnumber" value="[% cardnumber %]" />
666                         <input type="submit" value="Lift restriction" />
667                </form>
668                         </li>[% END %]
669
670                 [% IF ( odues ) %]<li>[% IF ( nonreturns ) %]<span class="circ-hlt">Overdues:</span> Patron has <span class="circ-hlt">ITEMS OVERDUE</span>. See highlighted items <a href="#checkouts">below</a>[% END %]</li>
671             [% END %]
672
673                 [% IF ( charges ) %]
674                             <li>
675             <span class="circ-hlt">Fees &amp; Charges:</span> Patron has  <a href="/cgi-bin/koha/members/boraccount.pl?borrowernumber=[% borrowernumber %]">Outstanding fees &amp; charges[% IF ( chargesamount ) %] of [% chargesamount %][% END %]</a>.
676                 [% IF ( charges_is_blocker ) %]
677                     Checkouts are <span class="circ-hlt">BLOCKED</span> because fine balance is <span class="circ-hlt">OVER THE LIMIT</span>.
678                 [% END %]
679             Make <a href="/cgi-bin/koha/members/pay.pl?borrowernumber=[% borrowernumber %]">Payment</a></li>
680                         [% END %]
681
682                 [% IF ( credits ) %]
683                         <li>
684                 <span class="circ-hlt">Credits:</span> Patron has a credit[% IF ( creditsamount ) %] of [% creditsamount %][% END %]
685             </li>
686                         [% END %]
687
688
689
690                         </ul>
691         </div>
692
693                         [% IF ( WaitingReserveLoop ) %]
694                         <div id="holdswaiting" class="circmessage">
695                     <h4>Holds waiting:</h4>
696                                 [% FOREACH WaitingReserveLoo IN WaitingReserveLoop %]
697                                     <ul>
698                                         <li> <a href="/cgi-bin/koha/reserve/request.pl?biblionumber=[% WaitingReserveLoo.biblionumber %]">[% WaitingReserveLoo.title |html %]</a> ([% WaitingReserveLoo.itemtype %]), [% IF ( WaitingReserveLoo.author ) %]by [% WaitingReserveLoo.author %][% END %] [% IF ( WaitingReserveLoo.itemcallnumber ) %][[% WaitingReserveLoo.itemcallnumber %]] [% END %]Hold placed on [% WaitingReserveLoo.reservedate %].
699                                     [% IF ( WaitingReserveLoo.waitingat ) %]
700                                         <br />[% IF ( WaitingReserveLoo.waitinghere ) %]<strong class="waitinghere">[% ELSE %]<strong>[% END %]Waiting at [% WaitingReserveLoo.waitingat %]</strong>
701                                     [% END %]
702                                         </li>
703                                     </ul>
704                             [% END %]
705                         </div>
706                         <!-- /If WaitingReserveLoop -->[% END %]
707         [% IF ( notes ) %]
708                         <div id="circnotes" class="circmessage">
709                         <h4>Notes:</h4>
710             <p><span class="circ-hlt">[% notesmsg %]</span></p>
711                         </div>
712
713
714     <!-- /If notes -->[% END %]
715
716         <div id="messages" class="circmessage">
717                 <h4>Messages:</h4>
718                 <ul>
719                         [% FOREACH lib_messages_loo IN lib_messages_loop %]
720                                 <li>
721                                         <span class="circ-hlt">
722                                                 [% lib_messages_loo.message_date_formatted %]
723                                                 [% lib_messages_loo.branchcode %]
724                                                 <i>"[% lib_messages_loo.message %]"</i>
725                                         </span>
726                                         [% IF ( lib_messages_loo.can_delete ) %]
727                                                 <a href="/cgi-bin/koha/circ/del_message.pl?message_id=[% lib_messages_loo.message_id %]&amp;borrowernumber=[% lib_messages_loo.borrowernumber %]">[Delete]</a>
728                                         [% ELSE %]
729                                                 [% IF ( all_messages_del ) %]
730                                                         <a href="/cgi-bin/koha/circ/del_message.pl?message_id=[% lib_messages_loo.message_id %]&amp;borrowernumber=[% lib_messages_loo.borrowernumber %]">[Delete]</a>
731                                                 [% END %]
732                                         [% END %]
733                                 </li>
734                         [% END %]
735                         [% FOREACH bor_messages_loo IN bor_messages_loop %]
736                                 <li><span class="">[% bor_messages_loo.message_date_formatted %] [% bor_messages_loo.branchcode %] <i>"[% bor_messages_loo.message %]"</i></span> [% IF ( bor_messages_loo.can_delete ) %]<a href="/cgi-bin/koha/circ/del_message.pl?message_id=[% bor_messages_loo.message_id %]&amp;borrowernumber=[% bor_messages_loo.borrowernumber %]">[Delete]</a>
737                 [% ELSIF ( all_messages_del ) %]
738                     <a href="/cgi-bin/koha/circ/del_message.pl?message_id=[% bor_messages_loo.message_id %]&amp;borrowernumber=[% bor_messages_loo.borrowernumber %]">[Delete]</a>
739                 [% END %]</li>
740                         [% END %]
741
742                 </ul>
743         </div>  
744         
745      <!-- /If flagged -->[% END %]
746
747         
748
749 </div>
750 </div>
751
752 <div class="yui-g"><div id="patronlists" class="toptabs">
753
754 <ul>
755 <li>    [% IF ( issuecount ) %]
756             <a href="#checkouts">[% issuecount %] Checkout(s)</a>
757     [% ELSE %]
758             <a href="#checkouts">0 Checkouts</a>
759     [% END %]</li>
760 [% IF ( displayrelissues ) %]
761 <li><a href="#relissues">Relatives' checkouts</a></li>
762 [% END %]
763 <li>[% IF ( countreserv ) %]
764             <a href="#reserves">[% countreserv %] Hold(s)</a>
765     [% ELSE %]
766             <a href="#reserves">0 Holds</a>
767     [% END %]</li>
768
769 </ul>
770
771 <!-- SUMMARY : TODAY & PREVIOUS ISSUES -->
772 <div id="checkouts">
773 [% IF ( issuecount ) %]
774     <form name="issues" action="/cgi-bin/koha/reserve/renewscript.pl" method="post" class="checkboxed">
775     <input type="hidden" value="circ" name="destination" />
776     <input type="hidden" name="cardnumber" value="[% cardnumber %]" />
777     <input type="hidden" name="borrowernumber" value="[% borrowernumber %]" />
778     <input type="hidden" name="branch" value="[% branch %]" />
779         <table id="issuest">
780     <thead><tr>
781         <th scope="col">Due date</th>
782         <th scope="col">Title</th>
783         <th scope="col">Item type</th>
784         <th scope="col">Checked out on</th>
785         <th scope="col">Checked out from</th>
786         <th scope="col">Call no</th>
787         <th scope="col">Charge</th>
788         <th scope="col">Price</th>
789         <th scope="col">Renew <p class="column-tool"><a href="#" id="CheckAllitems">select all</a> | <a href="#" id="CheckNoitems">none</a></p></th>
790         <th scope="col">Check in <p class="column-tool"><a href="#" id="CheckAllreturns">select all</a> | <a href="#" id="CheckNoreturns">none</a></p></th>
791         [% IF export_remove_fields OR export_with_csv_profile %]
792           <th scope="col">Export <p class="column-tool"><a href="#" id="CheckAllexports">select all</a> | <a href="#" id="CheckNoexports">none</a></p></th>
793         [% END %]
794     </tr>
795 [% IF ( todayissues ) %]</thead>
796 [% INCLUDE 'checkouts-table-footer.inc' %]
797         <tbody>
798
799     [% FOREACH todayissue IN todayissues %]
800     [% IF ( loop.odd ) %]
801     <tr>
802     [% ELSE %]
803     <tr class="highlight">
804     [% END %]
805         [% IF ( todayissue.od ) %]<td class="od">[% ELSE %]<td>[% END %]
806         [% todayissue.dd %]
807         </td>
808         <td><a href="/cgi-bin/koha/catalogue/detail.pl?biblionumber=[% todayissue.biblionumber %]&amp;type=intra"><strong>[% todayissue.title |html %]</strong></a>[% IF ( todayissue.author ) %], by [% todayissue.author %][% END %][% IF ( todayissue.itemnotes ) %]- <span class="circ-hlt">[% todayissue.itemnotes %]</span>[% END %] <a href="/cgi-bin/koha/catalogue/moredetail.pl?biblionumber=[% todayissue.biblionumber %]&amp;itemnumber=[% todayissue.itemnumber %]#item[% todayissue.itemnumber %]">[% todayissue.barcode %]</a></td>
809         <td>[% UNLESS ( noItemTypeImages ) %] [% IF ( todayissue.itemtype_image ) %]<img src="[% todayissue.itemtype_image %]" alt="" />[% END %][% END %][% todayissue.itemtype %]</td>
810         <td>[% todayissue.checkoutdate %]</td>
811         [% IF ( todayissue.multiple_borrowers ) %]<td>[% todayissue.firstname %] [% todayissue.surname %]</td>[% END %]
812         <td>[% todayissue.issuingbranchname %]</td>
813         <td>[% todayissue.itemcallnumber %]</td>
814             <td>[% todayissue.charge %]</td>
815             <td>[% todayissue.replacementprice %]</td>
816       [% IF ( todayissue.renew_failed ) %]
817             <td class="problem">Renewal failed</td>
818       [% ELSE %]
819         <td><span style="padding: 0 1em;">[% IF ( todayissue.renewals ) %][% todayissue.renewals %][% ELSE %]0[% END %]</span>
820         [% IF ( todayissue.can_renew ) %]
821         <input type="checkbox" name="all_items[]" value="[% todayissue.itemnumber %]" checked="checked" style="display: none;" />
822         [% IF ( todayissue.od ) %]
823             <input type="checkbox" class="radio" name="items[]" value="[% todayissue.itemnumber %]" checked="checked" />
824         [% ELSE %]
825             <input type="checkbox" class="radio" name="items[]" value="[% todayissue.itemnumber %]" />
826         [% END %]
827         [% ELSE %]
828             [% IF ( todayissue.can_confirm ) %]<span class="renewals-allowed" style="display: none">
829                 <input type="checkbox" name="all_items[]" value="[% todayissue.itemnumber %]" checked="checked" style="display: none;" />
830                 [% IF ( todayissue.od ) %]
831                     <input type="checkbox" class="radio" name="items[]" value="[% todayissue.itemnumber %]" checked="checked" />
832                 [% ELSE %]
833                     <input type="checkbox" class="radio" name="items[]" value="[% todayissue.itemnumber %]" />
834                 [% END %]
835                 </span>
836                 <span class="renewals-disabled">
837             [% END %]
838                 [% IF ( todayissue.renew_error_on_reserve ) %]
839             <a href="/cgi-bin/koha/reserve/request.pl?biblionumber=[% todayissue.biblionumber %]">On hold</a>
840                 [% END %]
841                 [% IF ( todayissue.renew_error_too_many ) %]
842             Not renewable
843                 [% END %]
844             [% IF ( todayissue.can_confirm ) %]
845                 </span>
846             [% END %]
847         [% END %]
848         </td>
849         [% END %]
850         [% IF ( todayissue.return_failed ) %]
851             <td class="problem">Checkin failed</td>
852         [% ELSE %]
853             [% IF ( todayissue.renew_error_on_reserve ) %]
854                <td><a href="/cgi-bin/koha/reserve/request.pl?biblionumber=[% todayissue.biblionumber %]">On hold</a>
855                 <input type="checkbox" name="all_barcodes[]" value="[% todayissue.barcode %]" checked="checked" style="display: none;" />
856                 </td>
857             [% ELSE %]
858             <td><input type="checkbox" class="radio" name="barcodes[]"  value="[% todayissue.barcode %]" />
859                 <input type="checkbox" name="all_barcodes[]" value="[% todayissue.barcode %]" checked="checked" style="display: none;" />
860             </td>
861             [% END %]
862         [% END %]
863         [% IF export_remove_fields OR export_with_csv_profile %]
864           <td style="text-align:center;">
865             <input type="checkbox" id="export_[% todayissue.biblionumber %]" name="biblionumbers" value="[% todayissue.biblionumber %]" />
866             <input type="checkbox" name="itemnumbers" value="[% todayissue.itemnumber %]" style="visibility:hidden;" />
867           </td>
868         [% END %]
869     </tr>
870     [% END %] <!-- /loop todayissues -->
871     <!-- /if todayissues -->[% END %]
872 [% IF ( previssues ) %]
873 [% IF ( todayissues ) %]<tr><th colspan="11"><a name="previous" id="previous"></a>Previous checkouts</th></tr>[% ELSE %]
874 <tr><th class="{sorter: false}" colspan="11"><a name="previous" id="previous"></a>Previous checkouts</th></tr></thead>
875 [% INCLUDE 'checkouts-table-footer.inc' %]
876         <tbody>
877 [% END %]
878     [% FOREACH previssue IN previssues %]
879     [% IF ( loop.odd ) %]
880         <tr>
881     [% ELSE %]
882         <tr class="highlight">
883     [% END %]
884         [% IF ( previssue.od ) %]<td class="od">[% ELSE %]<td>[% END %]
885         [% previssue.dd %]
886         </td>
887         <td><a href="/cgi-bin/koha/catalogue/detail.pl?biblionumber=[% previssue.biblionumber %]&amp;type=intra"><strong>[% previssue.title |html %]</strong></a>[% IF ( previssue.author ) %], by [% previssue.author %][% END %] [% IF ( previssue.itemnotes ) %]- [% previssue.itemnotes %][% END %] <a href="/cgi-bin/koha/catalogue/moredetail.pl?biblionumber=[% previssue.biblionumber %]&amp;itemnumber=[% previssue.itemnumber %]#item[% previssue.itemnumber %]">[% previssue.barcode %]</a></td>
888         <td>
889             [% previssue.itemtype %]
890         </td>
891         <td>[% previssue.displaydate %]</td>
892         [% IF ( previssue.multiple_borrowers ) %]<td>[% previssue.firstname %] [% previssue.surname %]</td>[% END %]
893         <td>[% previssue.issuingbranchname %]</td>
894         <td>[% previssue.itemcallnumber %]</td>
895         <td>[% previssue.charge %]</td>
896         <td>[% previssue.replacementprice %]</td>
897       [% IF ( previssue.renew_failed ) %]
898             <td class="problem">Renewal failed</td>
899       [% ELSE %]
900         <td><span style="padding: 0 1em;">[% IF ( previssue.renewals ) %][% previssue.renewals %][% ELSE %]0[% END %]</span>
901         [% IF ( previssue.can_renew ) %]
902         <input type="checkbox" name="all_items[]" value="[% previssue.itemnumber %]" checked="checked" style="display: none;" />
903         [% IF ( previssue.od ) %]
904             <input type="checkbox" class="radio" name="items[]" value="[% previssue.itemnumber %]" checked="checked" />
905         [% ELSE %]
906             <input type="checkbox" class="radio" name="items[]" value="[% previssue.itemnumber %]" />
907         [% END %]
908         [% ELSE %]
909             [% IF ( previssue.can_confirm ) %]<span class="renewals-allowed" style="display: none">
910                 <input type="checkbox" name="all_items[]" value="[% previssue.itemnumber %]" checked="checked" style="display: none;" />
911                 [% IF ( previssue.od ) %]
912                     <input type="checkbox" class="radio" name="items[]" value="[% previssue.itemnumber %]" checked="checked" />
913                 [% ELSE %]
914                     <input type="checkbox" class="radio" name="items[]" value="[% previssue.itemnumber %]" />
915                 [% END %]
916                 </span>
917                 <span class="renewals-disabled">
918             [% END %]
919                 [% IF ( previssue.renew_error_on_reserve ) %]
920             <a href="/cgi-bin/koha/reserve/request.pl?biblionumber=[% previssue.biblionumber %]">On hold</a>
921                 [% END %]
922                 [% IF ( previssue.renew_error_too_many ) %]
923             Not renewable
924                 [% END %]
925             [% IF ( previssue.can_confirm ) %]
926                 </span>
927             [% END %]
928         [% END %]
929         </td>
930         [% END %]
931                   [% IF ( previssue.return_failed ) %]
932             <td class="problem">Check-in failed</td>
933         [% ELSE %]
934             [% IF ( previssue.renew_error_on_reserve ) %]
935                <td><a href="/cgi-bin/koha/reserve/request.pl?biblionumber=[% previssue.biblionumber %]">On hold</a>
936                 <input type="checkbox" name="all_barcodes[]" value="[% previssue.barcode %]" checked="checked" style="display: none;" />
937                 </td>
938             [% ELSE %]
939             <td><input type="checkbox" class="radio" name="barcodes[]"  value="[% previssue.barcode %]" />
940                 <input type="checkbox" name="all_barcodes[]" value="[% previssue.barcode %]" checked="checked" style="display: none;" />
941             </td>
942             [% END %]
943         [% END %]
944         [% IF export_remove_fields OR export_with_csv_profile %]
945           <td style="text-align:center;">
946             <input type="checkbox" id="export_[% previssue.biblionumber %]" name="biblionumbers" value="[% previssue.biblionumber %]" />
947             <input type="checkbox" name="itemnumbers" value="[% previssue.itemnumber %]" style="visibility:hidden;" />
948           </td>
949         [% END %]
950     </tr>
951     <!-- /loop previssues -->[% END %]
952 <!--/if previssues -->[% END %]
953       </tbody>
954     </table>
955     [% IF ( issuecount ) %]
956     <fieldset class="action">
957         [% IF ( CAN_user_circulate_override_renewals ) %]
958         [% IF ( AllowRenewalLimitOverride ) %]
959         <label for="override_limit">Override renewal limit:</label>
960         <input type="checkbox" name="override_limit" id="override_limit" value="1" />
961         [% END %]
962         [% END %]
963         <input type="submit" name="renew_checked" value="Renew or Return checked items" />
964         <input type="submit" id="renew_all" name="renew_all" value="Renew all" />
965     </fieldset>
966         [% IF export_remove_fields OR export_with_csv_profile %]
967             <fieldset>
968             <label for="export_formats"><b>Export checkouts using format:</b></label>
969             <select name="export_formats" id="export_formats">
970                 <option value="iso2709_995">ISO2709 with items</option>
971                 <option value="iso2709">ISO2709 without items</option>
972                 <option value="csv">CSV</option>
973             </select>
974            <label for="export_remove_fields">Don't export fields:</label> <input type="text" id="export_remove_fields" name="export_remove_fields" value="[% export_remove_fields %]" title="Use for iso2709 exports" />
975             <input type="hidden" name="op" value="export" />
976             <input type="hidden" id="export_format" name="format" value="iso2709" />
977             <input type="hidden" id="dont_export_item" name="dont_export_item" value="0" />
978             <input type="hidden" id="record_type" name="record_type" value="bibs" />
979             <input type="button" id="export_submit" value="Export" />
980             </fieldset>
981         [% END %]
982     [% END %]
983     </form>
984 [% ELSE %]
985 <p>Patron has nothing checked out.</p>
986 [% END %]
987
988 </div>
989
990
991 [% IF ( displayrelissues ) %]
992 <div id="relissues">
993     <table id="relissuest">
994     <thead>
995     <tr>
996         <th scope="col">Due date</th>
997         <th scope="col">Title</th>
998         <th scope="col">Item type</th>
999         <th scope="col">Checked out on</th>
1000         <th scope="col">Checked out from</th>
1001         <th scope="col">Call no</th>
1002         <th scope="col">Charge</th>
1003         <th scope="col">Price</th>
1004         <th scope="col">Patron</th>
1005     </tr>
1006     </thead>
1007 [% IF ( relissues ) %]  <tbody>
1008
1009     [% FOREACH relissue IN relissues %]
1010     [% IF ( loop.odd ) %]
1011     <tr>
1012     [% ELSE %]
1013     <tr class="highlight">
1014     [% END %]
1015         [% IF ( relissue.overdue ) %]<td class="od">[% ELSE %]<td>[% END %]
1016             [% relissue.dd %]</td>
1017         <td><a href="/cgi-bin/koha/catalogue/detail.pl?biblionumber=[% relissue.biblionumber %]&amp;type=intra"><strong>[% relissue.title |html %]</strong></a>[% IF ( relissue.author ) %], by [% relissue.author %][% END %][% IF ( relissue.itemnotes ) %]- <span class="circ-hlt">[% relissue.itemnotes %]</span>[% END %] <a href="/cgi-bin/koha/catalogue/moredetail.pl?biblionumber=[% relissue.biblionumber %]&amp;itemnumber=[% relissue.itemnumber %]#item[% relissue.itemnumber %]">[% relissue.barcode %]</a></td>
1018         <td>[% UNLESS ( noItemTypeImages ) %] [% IF ( relissue.itemtype_image ) %]<img src="[% relissue.itemtype_image %]" alt="" />[% END %][% END %][% relissue.itemtype %]</td>
1019         <td>[% relissue.displaydate %]</td>
1020         <td>[% relissue.issuingbranchname %]</td>
1021         <td>[% relissue.itemcallnumber %]</td>
1022         <td>[% relissue.charge %]</td>
1023         <td>[% relissue.replacementprice %]</td><td><a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% relissue.borrowernumber %]">[% relissue.firstname %] [% relissue.surname %] ([% relissue.cardnumber %])</a></td>
1024      </tr>
1025     [% END %] <!-- /loop relissues -->
1026     <!-- /if relissues -->[% END %]
1027 [% IF ( relprevissues ) %]
1028 <tr><th class="{sorter: false}" colspan="11"><a name="relprevious" id="relprevious"></a>Previous checkouts</th></tr>
1029     [% FOREACH relprevissue IN relprevissues %]
1030     [% IF ( loop.odd ) %]
1031         <tr>
1032     [% ELSE %]
1033         <tr class="highlight">
1034     [% END %]
1035         [% IF ( relprevissue.overdue ) %]<td class="od">[% ELSE %]<td>[% END %]
1036         [% relprevissue.dd %]
1037         </td>
1038         <td><a href="/cgi-bin/koha/catalogue/detail.pl?biblionumber=[% relprevissue.biblionumber %]&amp;type=intra"><strong>[% relprevissue.title |html %]</strong></a>[% IF ( relprevissue.author ) %], by [% relprevissue.author %][% END %] [% IF ( relprevissue.itemnotes ) %]- [% relprevissue.itemnotes %][% END %] <a href="/cgi-bin/koha/catalogue/moredetail.pl?biblionumber=[% relprevissue.biblionumber %]&amp;itemnumber=[% relprevissue.itemnumber %]#item[% relprevissue.itemnumber %]">[% relprevissue.barcode %]</a></td>
1039         <td>[% UNLESS noItemTypeImages %][% IF relprevissue.itemtype_image %]<img src="[% relprevissue.itemtype_image %]" alt="" />[% END %][% END %][% relprevissue.itemtype %]</td>
1040         <td>[% relprevissue.displaydate %]</td>
1041         <td>[% relprevissue.issuingbranchname %]</td>
1042         <td>[% relprevissue.itemcallnumber %]</td>
1043         [% IF ( relprevissue.multiple_borrowers ) %]<td>[% relprevissue.firstname %] [% relprevissue.surname %]</td>[% END %]
1044         <td>[% relprevissue.charge %]</td>
1045         <td>[% relprevissue.replacementprice %]</td>
1046         <td><a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% relprevissue.borrowernumber %]">[% relprevissue.firstname %] [% relprevissue.surname %] ([% relprevissue.cardnumber %])</a></td>
1047
1048     </tr>
1049     <!-- /loop relprevissue -->[% END %]
1050 <!--/if relprevissues -->[% END %]
1051       </tbody>
1052     </table>
1053
1054 </div>
1055 [% END %]<!-- end displayrelissues -->
1056
1057
1058 <div id="reserves">
1059 [% IF ( reservloop ) %]
1060     <form action="/cgi-bin/koha/reserve/modrequest.pl" method="post">
1061         <input type="hidden" name="from" value="circ" />
1062     <table id="holdst">
1063         <thead><tr>
1064             <th>Hold date</th>
1065             <th>Title</th>
1066             <th>Call number</th>
1067             <th>Barcode</th>
1068             <th>Priority</th>
1069             <th>Delete?</th>
1070             <th>&nbsp;</th>
1071         </tr></thead>
1072                 <tbody>
1073         [% FOREACH reservloo IN reservloop %]
1074         <tr class="[% reservloo.color %]">
1075                     <td>[% reservloo.reservedate %]</td>
1076                     <td><a href="/cgi-bin/koha/reserve/request.pl?biblionumber=[% reservloo.biblionumber %]"><strong>[% reservloo.title |html %]</strong></a>[% IF ( reservloo.author ) %], by [% reservloo.author %][% END %]</td>
1077                     <td>[% reservloo.itemcallnumber %]</td>
1078                                         <td><em>[% IF ( reservloo.barcodereserv ) %]Item [% reservloo.barcodereserv %]
1079                         [% END %][% IF ( reservloo.waiting ) %] <strong>waiting at [% reservloo.waitingat %]</strong>
1080                         [% END %]
1081                         [% IF ( reservloo.transfered ) %] <strong>in transit</strong> from
1082                         [% reservloo.frombranch %] since [% reservloo.datesent %]
1083                         [% END %]
1084                         [% IF ( reservloo.nottransfered ) %] hasn't been transferred yet from [% reservloo.nottransferedby %]</i>
1085                         [% END %]</em></td>
1086                     <td>
1087                         [% IF ( reservloo.waitingposition ) %]<b> [% reservloo.waitingposition %] </b>[% END %]
1088                     </td>
1089                                 <td><select name="rank-request">
1090                     <option value="n">No</option>
1091                     <option value="del">Yes</option>
1092                 </select>
1093                 <input type="hidden" name="biblionumber" value="[% reservloo.biblionumber %]" />
1094                 <input type="hidden" name="borrowernumber" value="[% borrowernumber %]" />
1095                 <input type="hidden" name="reservenumber" value="[% reservloo.reservenumber %]" />
1096             </td>
1097             <td>[% IF ( reservloo.suspend ) %]Suspended [% IF ( reservloo.suspend_until ) %] until [% reservloo.suspend_until | $KohaDates %][% END %][% END %]</td>
1098             </tr>
1099         [% END %]</tbody>
1100     </table>
1101             <fieldset class="action"><input type="submit" class="cancel" name="submit" value="Cancel marked holds" /></fieldset>
1102     </form>
1103
1104     [% IF SuspendHoldsIntranet %]
1105     <fieldset class="action">
1106         <form action="/cgi-bin/koha/reserve/modrequest_suspendall.pl" method="post">
1107             <input type="hidden" name="from" value="circ" />
1108             <input type="hidden" name="borrowernumber" value="[% borrowernumber %]" />
1109             <input type="submit" value="Suspend all holds" />
1110
1111             [% IF AutoResumeSuspendedHolds %]
1112             <label for="suspend_until">until</label>
1113             <input type="text" size="10" id="suspend_until" name="suspend_until" class="datepicker" />
1114             <span class="hint">Specify date on which to resume [% INCLUDE 'date-format.inc' %]: </span>
1115              [% END %]
1116         </form>
1117     </fieldset>
1118
1119     <fieldset class="action">
1120         <form action="/cgi-bin/koha/reserve/modrequest_suspendall.pl" method="post">
1121             <input type="hidden" name="from" value="circ" />
1122             <input type="hidden" name="borrowernumber" value="[% borrowernumber %]" />
1123             <input type="hidden" name="suspend" value="0" />
1124             <input type="submit" value="Resume all suspended holds" />
1125         </form>
1126     </fieldset>
1127     [% END # IF SuspendHoldsIntranet %]
1128
1129 [% ELSE %]
1130         <p>Patron has nothing on hold.</p>
1131 [% END %]
1132 </div> <!-- reservesloop -->
1133
1134 [% END %] <!-- borrowernumber -->
1135 </div></div>
1136 [% END %]
1137
1138
1139
1140 </div>
1141 </div>
1142 [% UNLESS ( CGIselectborrower ) %][% IF ( borrowernumber ) %]<div class="yui-b">
1143 [% INCLUDE 'circ-menu.inc' %]
1144 </div>[% END %][% END %]
1145 </div>
1146 [% INCLUDE 'intranet-bottom.inc' %]