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