Merge remote-tracking branch 'origin/new/bug_7548'
[koha.git] / koha-tmpl / intranet-tmpl / prog / en / modules / members / moremember.tt
1 [% INCLUDE 'doc-head-open.inc' %]
2 <title>Koha &rsaquo; Patrons &rsaquo;
3 [% IF ( unknowuser ) %]
4     Patron does not exist
5 [% ELSE %]
6     Patron Details for [% INCLUDE 'patron-title.inc' %]
7 [% END %]
8 </title>
9 [% INCLUDE 'doc-head-close.inc' %]
10 [% INCLUDE 'calendar.inc' %]
11 <script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.tablesorter.min.js"></script>
12 <script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.checkboxes.min.js"></script>
13 <script type="text/JavaScript" language="JavaScript">
14 //<![CDATA[
15 $.tablesorter.addParser({
16     id: 'articles', 
17     is: function(s) {return false;  }, 
18     format: function(s) { return s.toLowerCase().replace(/^(the|an|a) /,''); }, 
19     type: 'text' 
20 });
21 $(document).ready(function() {
22         $('#finesholdsissues > ul').tabs();
23         $.tablesorter.defaults.widgets = ['zebra'];
24         $("#issuest").tablesorter({[% IF ( dateformat_metric ) %]
25                 dateFormat: 'uk',[% END %]
26         headers: { 1: { sorter: 'articles'},8:{sorter:false},9:{sorter:false }}
27         }); 
28         $("#relissuest").tablesorter({[% IF ( dateformat_metric ) %]
29                 dateFormat: 'uk',[% END %]
30                 headers: { 1: { sorter: 'articles'},8:{sorter:false},9:{sorter:false }}
31         }); 
32         $("#holdst").tablesorter({[% IF ( dateformat_metric ) %]
33                 dateFormat: 'uk',[% END %]
34                 sortList: [[0,0]],
35                 headers: { 1: { sorter: 'articles' },5: { sorter: false }}
36         }); 
37     [% IF ( picture ) %]
38     // new YAHOO.widget.Button("delpicture");   // FIXME: formatting mismatch between YUI and normal button
39         $('#delpicture').click(function(){
40                  return confirm(_('Are you sure you want to delete this patron image? This cannot be undone.'));
41         });
42         $('#manage-patron-image').find("input[value*=Upload]").click(function(){
43         if($("#uploadfile").val() == ""){
44             alert(_("Please choose a file to upload"));
45             return false;
46         }
47         return confirm(_('Are you sure you want to replace the current patron image? This cannot be undone.'));
48         });[% END %]
49         $("#renew_all"      ).click(function(){ $(".checkboxed").checkCheckboxes(":input[name*=items]"   ); $(".checkboxed").unCheckCheckboxes(":input[name*=barcodes]"); });
50         $("#CheckAllitems"  ).click(function(){ $(".checkboxed").checkCheckboxes(":input[name*=items]"   ); $(".checkboxed").unCheckCheckboxes(":input[name*=barcodes]"); return false; });
51     $("#CheckNoitems"   ).click(function(){ $(".checkboxed").unCheckCheckboxes(":input[name*=items]"); return false; });
52         $("#CheckAllreturns").click(function(){ $(".checkboxed").checkCheckboxes(":input[name*=barcodes]"); $(".checkboxed").unCheckCheckboxes(":input[name*=items]"); return false; });
53     $("#CheckNoreturns" ).click(function(){ $(".checkboxed").unCheckCheckboxes(":input[name*=barcodes]"); return false; });
54
55     $("#relrenew_all"      ).click(function(){ $(".checkboxed").checkCheckboxes(":input[name*=items]"   ); $(".checkboxed").unCheckCheckboxes(":input[name*=barcodes]"); });
56     $("#relCheckAllitems"  ).click(function(){ $(".checkboxed").checkCheckboxes(":input[name*=items]"   ); $(".checkboxed").unCheckCheckboxes(":input[name*=barcodes]"); return false; });
57     $("#relCheckNoitems"   ).click(function(){ $(".checkboxed").unCheckCheckboxes(":input[name*=items]"); return false; });
58     $("#relCheckAllreturns").click(function(){ $(".checkboxed").checkCheckboxes(":input[name*=barcodes]"); $(".checkboxed").unCheckCheckboxes(":input[name*=items]"); return false; });
59     $("#relCheckNoreturns" ).click(function(){ $(".checkboxed").unCheckCheckboxes(":input[name*=barcodes]"); return false; });
60
61
62     [% IF ( CAN_user_circulate_override_renewals ) %]
63     [% IF ( AllowRenewalLimitOverride ) %]
64     $( '#override_limit' ).click( function () {
65         if ( this.checked ) {
66            $( '.renewals-allowed' ).show(); $( '.renewals-disabled' ).hide();
67         } else {
68            $( '.renewals-allowed' ).hide(); $( '.renewals-disabled' ).show();
69         }
70     } ).attr( 'checked', false );
71     [% END %]
72     [% END %]
73         $("td").click(function(e){
74                 if(e.target.tagName.toLowerCase() == 'td'){
75            $(this).find("input:checkbox").each( function() {
76                $(this).attr('checked', !$(this).attr('checked'));
77                            if($(this).attr('checked')){
78                     $(this).parent().siblings().find("input:checkbox").each(function(){
79                        if($(this).attr('checked')){ $(this).attr('checked',''); }
80                    });
81                            }
82            });
83                 }
84         });
85  });
86 function uncheck_sibling(me){
87 nodename=me.getAttribute("name");
88 if (nodename =="barcodes[]"){
89     var Node=me.parentNode.previousSibling;
90     while (Node.nodeName!="TD"){Node=Node.previousSibling}
91     var Nodes=Node.childNodes;
92     for (var i=0;i<Nodes.length;i++){
93       if (Nodes[i].nodeName=="INPUT" && Nodes[i].getAttribute("type")=="checkbox"){
94         Nodes[i].checked=false;
95       }     
96    }   
97
98 }else {
99     var Node=me.parentNode.nextSibling;
100     while (Node.nodeName!="TD"){Node=Node.nextSibling}
101     var Nodes=Node.childNodes;
102     for (var i=0;i<Nodes.length;i++){
103       if (Nodes[i].nodeName=="INPUT" && Nodes[i].getAttribute("type")=="checkbox"){
104         Nodes[i].checked=false;
105       }     
106    }   
107 }
108 }
109 function validate1(date) {
110     var today = new Date();
111     if ( date < today ) {
112         return true;
113      } else {
114         return false;
115      }
116 };
117 //]]>
118 </script>
119
120 </head>
121 <body id="pat_moremember" class="pat">
122 [% INCLUDE 'header.inc' %]
123 [% INCLUDE 'patron-search.inc' %]
124
125 <div id="breadcrumbs">
126          <a href="/cgi-bin/koha/mainpage.pl">Home</a>
127 &rsaquo; <a href="/cgi-bin/koha/members/members-home.pl">Patrons</a>
128 &rsaquo; [% IF ( unknowuser ) %]Patron does not exist[% ELSE %]Patron Details for [% INCLUDE 'patron-title.inc' %][% END %]
129 </div>
130
131 <div id="doc3" class="yui-t1">
132    
133    <div id="bd">
134         <div id="yui-main">
135         <div class="yui-b">
136 [% INCLUDE 'members-toolbar.inc' %]
137 [% IF ( error ) %]
138 <div class="dialog alert">
139     [% IF ( AUTH_UPDATE_FAILED ) %]
140         <h3>Userid / Password update failed</h3>
141         <strong>Insufficient privileges.</strong>
142         <p>Other fields updated.</p>
143     [% END %]
144     [% IF ( CANT_DELETE_STAFF ) %]
145         <h3>Unable to delete staff user</h3>
146         <p>Insufficient privileges.</p>
147     [% END %]
148     [% IF ( CANT_DELETE_OTHERLIBRARY ) %]
149         <h3>Unable to delete patrons from other libraries with current settings</h3>
150         <p>Insufficient privileges.</p>
151     [% END %]
152     [% IF ( CANT_DELETE ) %]
153         <h3>Unable to delete patron</h3>
154         <p>Insufficient privileges.</p>
155     [% END %]
156 </div>
157 [% END %]
158 <div class="yui-g">
159
160 [% IF ( unknowuser ) %]
161    <div class="dialog message">This patron does not exist.</div>
162 [% ELSE %]
163     [% IF ( reregistration ) %]<div class="dialog message">Patron's account has been renewed until [% dateexpiry %]</div>[% END %]
164
165     [% IF ( flagged ) %]
166     <ul>
167         [% IF ( userdebarred ) %]
168             <li>Patron is restricted[% IF ( userdebarreddate ) %] until [% userdebarreddate%] [% IF (debarredcomment ) %]([% debarredcomment %])[% END %][% END %]
169             <form class="inline compact" action="/cgi-bin/koha/members/setdebar.pl" method="post">
170                 <input type="hidden" name="borrowernumber" value="[% borrowernumber %]" />
171                 <input type="submit" value="Lift Restriction" />
172             </form>
173             </li>
174         [% END %]
175         [% IF ( gonenoaddress ) %]<li>Patron's address is in doubt.</li>[% END %]
176         [% IF ( lost ) %]<li>Patron's card has been reported lost.</li>[% END %]
177     </ul>
178     [% END %]
179
180 <h3>[% UNLESS ( I ) %]
181    [% title %] [% firstname %] [% END %] [% surname %] ([% cardnumber %])</h3>
182  <div class="yui-u first">
183 <div id="patron-information" style="padding : .5em;">
184
185      [% UNLESS ( I ) %][% IF ( othernames ) %]&ldquo;[% othernames %]&rdquo;[% END %]
186
187 <p class="address">[% streetnumber %]
188         [% IF ( roaddetails ) %]
189          [% roaddetails %]
190         [% END %]
191         [% address %]<br />
192         [% IF ( address2 ) %][% address2 %]<br />[% END %]
193         [% IF ( city ) %][% city %][% END %] 
194         [% IF ( state ) %][% state %][% END %]
195         [% IF ( zipcode ) %][% zipcode %]<br />[% END %]
196         [% IF ( country ) %][% country %][% END %]</p>
197                     
198         <div class="rows">
199                 <ol>
200         [% IF ( I ) %]
201             [% IF ( phonepro ) %]<li><span class="label">Organization phone: </span>[% phonepro %]</li>[% END %]
202             [% IF ( emailpro ) %]<li><span class="label">Organization email: </span>[% emailpro %]</li>[% END %]
203         [% ELSE %]
204             [% IF ( phone ) %]<li><span class="label">Primary phone: </span>[% phone %]</li>[% END %]
205             [% IF ( mobile ) %]<li><span class="label">Secondary phone: </span>[% mobile %]</li>[% END %]
206             [% IF ( phonepro ) %]<li><span class="label">Other phone: </span>[% phonepro %]</li>[% END %]
207         [% END %]
208
209     [% IF ( P ) %]
210         [% IF ( phone ) %]<li><span class="label">Primary phone: </span>[% phone %]</li>[% END %]
211         [% IF ( mobile ) %]<li><span class="label">Secondary phone: </span>[% mobile %]</li>[% END %]
212     [% END %]           
213         [% IF ( fax ) %]<li><span class="label">Fax: </span>[% fax %]</li>[% END %]
214     [% UNLESS ( I ) %]
215         [% IF ( email ) %]<li><span class="label">Primary email:</span><a href="mailto:[% email %]">[% email %]</a></li>[% END %]
216         [% IF ( emailpro ) %]<li><span class="label">Secondary email: </span><a href="mailto:[% emailpro %]">[% emailpro %]</a></li>[% END %]
217     [% END %]
218     [% IF ( initials ) %]<li><span class="label">Initials: </span>[% initials %]</li>[% END %]
219     [% IF ( dateofbirth ) %]<li><span class="label">Date of birth:</span>[% dateofbirth %]</li>[% END %]
220     [% IF ( sex ) %]<li><span class="label">Gender:</span>
221     [% IF ( sex == 'F' ) %]Female[% ELSIF ( sex == 'M' ) %]Male[% ELSE %][% sex %][% END %]
222     </li>[% END %][% END %]
223     [% IF ( printethnicityline ) %]
224     <li><span class="label">Ethnicity:</span>[% ethnicity %]</li>
225     <li><span class="label">Ethnicity notes: </span>[% ethnotes %]</li>
226     [% END %]
227     [% IF ( isguarantee ) %]
228         [% IF ( guaranteeloop ) %]
229             <li><span class="label">Guarantees:</span><ul>[% FOREACH guaranteeloo IN guaranteeloop %]<li><a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% guaranteeloo.borrowernumber %]">[% guaranteeloo.name %]  </a></li>[% END %]</ul></li>
230         [% END %]
231     [% ELSE %]
232         [% IF ( guarantorborrowernumber ) %]
233             <li><span class="label">Guarantor:</span><a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% guarantorborrowernumber %]">[% guarantorsurname %], [% guarantorfirstname %]</a></li>
234         [% END %]
235     [% END %]
236 </ol>
237 </div>
238       <div class="action">
239         [% IF ( guarantorborrowernumber ) %]
240         <a href="memberentry.pl?op=modify&amp;borrowernumber=[% borrowernumber %]&amp;step=1&amp;guarantorid=[% guarantorborrowernumber %]">Edit</a>
241         [% ELSE %]
242         <a href="memberentry.pl?op=modify&amp;borrowernumber=[% borrowernumber %]&amp;step=1">Edit</a>
243         [% END %]</div>
244
245 </div>
246
247 <!-- Begin Upload Patron Image Section -->
248
249 <div id="manage-patron-image">
250 [% IF ( patronimages ) %]
251     [% IF ( CAN_user_tools_batch_upload_patron_images ) %]
252         <form method="post" action="/cgi-bin/koha/tools/picture-upload.pl" enctype="multipart/form-data">
253             <fieldset class="brief">
254             [% IF ( picture ) %]
255                 <legend>Manage Patron Image</legend>
256                 <div class="hint">To update the image for [% title %] [% surname %], select a new image file and click 'Upload.' <br />Click the 'Delete' button to remove the current image.
257             [% ELSE %]
258                 <legend>Upload Patron Image</legend>
259                 <div class="hint">[% title %] [% firstname %] [% surname %] does not currently have an image available. To import an image for [% title %] [% surname %], enter the name of an image file to upload.
260             [% END %]
261                     <br />Only PNG, GIF, JPEG, XPM formats are supported.
262                 </div>
263                 <input type="hidden" id="image" name="filetype" value="image" />
264                 <input type="hidden" id="cardnumber" name="cardnumber" value="[% cardnumber %]" />
265                 <input type="hidden" name="borrowernumber" value="[% borrowernumber %]" />
266                 <ol>
267                     <li>
268                        <label for="uploadfile">Select the file to upload: </label><input type="file" id="uploadfile" name="uploadfile" />
269                     </li>
270                 </ol>
271                 <fieldset class="action">
272                     <input type="submit" value="Upload" class="submit" />
273                     <input name="op" type="hidden" value="Upload" />
274                     [% IF ( picture ) %]<a id="delpicture" href="/cgi-bin/koha/tools/picture-upload.pl?op=Delete&amp;cardnumber=[% cardnumber %]&amp;borrowernumber=[% borrowernumber %]" class="delete">Delete</a>[% END %]
275                 </fieldset>
276             </fieldset>
277         </form>
278     [% END %]
279 [% END %]
280 </div>
281
282 <!-- End Upload Patron Image Section -->
283
284 [% IF ( ExtendedPatronAttributes ) %]
285 [% UNLESS ( no_patron_attribute_types ) %]
286 <div id="patron-extended-attributes" style="padding-top: 1em;">
287 <h3>Additional attributes and identifiers</h3>
288 [% FOREACH attribute IN attributes_loop %]
289     [% IF attribute.class %]
290         <h4>[% attribute.lib %]</h4>
291         <table id=aai_[% attribute.class %]>
292     [% ELSE %]
293         <table id="aai">
294     [% END %]
295         <thead>
296             <tr>
297                 <th>Type</th>
298                 <th>Description</th>
299                 <th>Value</th>
300             </tr>
301         </thead>
302         <tbody>
303         [% FOREACH item IN attribute.items %]
304             <tr>
305                 <td>[% item.code %]</td>
306                 <td>[% item.description %]</td>
307                 <td>[% item.value %]
308                     [% IF ( item.value_description ) %]
309                         ([% item.value_description %])
310                     [% END %]
311                 </td>
312             </tr>
313         [% END %]
314         </tbody>
315     </table>
316 [% END %]
317 </div>
318 <div class="action"><a href="memberentry.pl?op=modify&amp;borrowernumber=[% borrowernumber %]&amp;step=4">Edit</a></div>
319 [% END %]
320 [% END %]
321
322 [% IF ( EnhancedMessagingPreferences ) %]
323 <div id="patron-messaging-prefs" style="padding-top: 1em;">
324 <h3>Patron messaging preferences</h3>
325 [% INCLUDE 'messaging-preference-form.inc' %]
326  [% IF ( SMSSendDriver ) %]
327       <div class="rows"> <ol><li><span class="label">SMS number:</span>[% SMSnumber %]
328      </li></ol></div>
329  [% END %]
330 </div>
331 <div class="action"><a href="memberentry.pl?op=modify&amp;borrowernumber=[% borrowernumber %]&amp;step=5">Edit</a></div>
332 [% END %]
333
334 </div>
335  <div class="yui-u"> 
336  <div id="patron-library-details">
337  <h3>Library use</h3>
338 <div class="rows"> 
339 <ol>
340     <li><span class="label">Card number: </span>[% cardnumber %]</li>
341         <li><span class="label">Borrowernumber: </span> [% borrowernumber %]</li>
342     <li><span class="label">Category: </span>[% description %] ([% categorycode %])</li>
343     <li><span class="label">Registration date: </span>[% dateenrolled %]</li>
344     
345     <li><span class="label">Expiration date: </span>
346     [% IF ( reregistration ) %]
347             <strong class="reregistrinfo">[% dateexpiry %]</span>
348     [% ELSE %]
349             [% dateexpiry %]
350     [% END %]
351     </li>
352     
353     <li><span class="label">Library: </span>[% branchname %]</li>
354
355     [% IF ( OPACPrivacy ) %]<li><span class="label">Privacy Pref:</span>
356          [% IF ( privacy0 ) %]Forever[% END %]
357          [% IF ( privacy1 ) %]Default[% END %]
358          [% IF ( privacy2 ) %]Never[% END %]
359     </li>[% END %]
360     [% IF ( sort1 ) %]<li><span class="label">Sort field 1:</span>[% lib1 %]</li>[% END %]
361     [% IF ( sort2 ) %]<li><span class="label">Sort field 2:</span>[% lib2 %]</li>[% END %]
362     <li><span class="label">Username: </span>[% userid %]</li>
363     <li><span class="label">Password: </span>
364     [% IF ( password ) %]
365         *******
366     [% ELSE %]
367         <span class="problem"><a href="/cgi-bin/koha/members/member-password.pl?member=[% borrowernumber %]">Undefined</a></span>
368     [% END %] 
369     </li>
370     [% IF ( borrowernotes ) %]<li><span class="label">Circulation note: </span>[% borrowernotes %]</li>[% END %]
371     [% IF ( opacnote ) %]<li><span class="label">OPAC note:</span>[% opacnote %]</li>[% END %]
372         </ol>
373         </div>
374  </div>
375     <div class="action"><a href="memberentry.pl?op=modify&amp;borrowernumber=[% borrowernumber %]&amp;step=3">Edit</a></div>
376  
377     [% UNLESS ( I ) %]
378  <div id="patron-alternate-address" style="padding-top: 1em;">
379     <h3>Alternate Address</h3>
380     <div class="rows">  <ol><li><span class="label">Address: </span>[% B_address %]</li>
381       <li><span class="label">Address 2: </span>[% B_address2 %]</li>
382       <li><span class="label">City: </span>[% B_city %]</li>
383       [% IF ( B_state ) %]<li><span class="label">State: </span>[% B_state %]</li>[% END %]
384       <li><span class="label">Zip/Postal Code: </span>[% B_zipcode %]</li>
385       [% IF ( B_country ) %]<li><span class="label">Country: </span>[% B_country %]</li>[% END %]
386       [% IF ( B_phone ) %]<li><span class="label">Phone: </span>[% B_phone %]</li>[% END %]
387       [% IF ( B_email ) %]<li><span class="label">Email: </span><a href="mailto:[% B_email %]">[% email %]</a></li>[% END %]</ol></div>
388 </div>
389 <div class="action"><a href="memberentry.pl?op=modify&amp;borrowernumber=[% borrowernumber %]&amp;step=6">Edit</a></div>
390     [% END %]
391
392  <div id="patron-alternative-contact" style="padding-top: 1em;">
393  <h3>Alternative Contact</h3>   
394    <div class="rows"> <ol><li><span class="label">Surname: </span>[% altcontactsurname %]</li>
395     <li><span class="label">First name: </span>[% altcontactfirstname %]</li>    
396     <li><span class="label">Address: </span>[% altcontactaddress1 %]</li>
397     <li><span class="label">Address 2: </span>[% altcontactaddress2 %]</li>
398         <li><span class="label">City: </span>[% altcontactaddress3 %]</li>
399     [% IF ( altcontactstate ) %]<li><span class="label">State: </span>[% altcontactstate %]</li>[% END %]
400         <li><span class="label">Zip/Postal Code: </span>[% altcontactzipcode %]</li>
401         [% IF ( altcontactcountry ) %]<li><span class="label">Country: </span>[% altcontactcountry %]</li>[% END %]
402     [% IF ( altcontactphone ) %]<li><span class="label">Phone: </span>[% altcontactphone %]</li>[% END %]
403     </ol></div>
404 </div>
405 <div class="action"><a href="memberentry.pl?op=modify&amp;borrowernumber=[% borrowernumber %]&amp;step=2">Edit</a></div>
406
407 </div>
408 </div>
409
410 <div id="finesholdsissues" class="toptabs">
411         <ul>
412                 <li><a href="/cgi-bin/koha/members/moremember.pl#checkedout">[% issueloop.size %] Checkout(s)</a></li>
413     [% IF relissueloop.size %]
414         <li><a href="/cgi-bin/koha/members/moremember.pl#relissues">Relatives' Checkouts</a></li>
415     [% END %]
416                 <li><a href="/cgi-bin/koha/members/moremember.pl#finesandcharges">Fines &amp; Charges</a></li>
417                 <li>[% IF ( countreserv ) %]
418             <a href="/cgi-bin/koha/members/moremember.pl#onhold">[% countreserv %] Hold(s)</a>
419     [% ELSE %]
420             <a href="/cgi-bin/koha/members/moremember.pl#onhold">0 Holds</a>
421     [% END %]</li>
422         </ul>
423         
424 <div id="finesandcharges">
425     [% IF ( totaldue_raw ) %]
426         <p>Total due: [% totaldue %]</p>
427     [% ELSE %]
428         <p>No outstanding charges</p>
429     [% END %]
430 </div>
431
432     <form action="/cgi-bin/koha/reserve/renewscript.pl" method="post" class="checkboxed">
433     <input type="hidden" name="borrowernumber" value="[% borrowernumber %]" />
434         <input type="hidden" name="branch" value="[% branch %]" />
435 <div id="checkedout">
436     [% IF ( issueloop ) %]
437     <table id="issuest">
438     <thead>
439                 <tr>
440             <th scope="col">Due date</th>
441             <th scope="col">Title</th>
442             <th scope="col">Item Type</th>
443             <th scope="col">Checked out on</th> 
444             <th scope="col">Checked out from</th> 
445             <th scope="col">Call no</th>
446             <th scope="col">Charge</th>
447             <th scope="col">Price</th>
448             <th scope="col">Renew <p class="column-tool"><a href="#" id="CheckAllitems">select all</a> | <a href="#" id="CheckNoitems">none</a></p></th>
449             <th scope="col">Check in <p class="column-tool"><a href="#" id="CheckAllreturns">select all</a> | <a href="#" id="CheckNoreturns">none</a></p></th>
450         </tr></thead>
451         [% INCLUDE 'checkouts-table-footer.inc' %]
452        <tbody>
453        [% FOREACH issueloo IN issueloop %]
454
455           [% IF ( issueloo.overdue ) %]
456           <tr class="problem">
457           [% ELSE %]
458           <tr>
459           [% END %]
460           [% IF ( issueloo.red ) %]
461                       <td class="od">
462           [% ELSE %]
463             <td>
464           [% END %]
465                 [% issueloo.date_due %]
466                 [% IF ( issueloo.itemlost ) %]
467                                         <span class="lost">[% issueloo.itemlost %]</span>
468                     [% END %]
469                 [% IF ( issueloo.damaged ) %]
470                                         <span class="dmg">[% issueloo.itemdamaged %]</span>
471                 [% END %]
472 </td>
473             <td><a href="/cgi-bin/koha/catalogue/detail.pl?biblionumber=[% issueloo.biblionumber %]"><strong>[% issueloo.title |html %]</strong></a>[% IF ( issueloo.author ) %], by [% issueloo.author %][% END %] [% IF ( issueloo.publishercode ) %]; [% issueloo.publishercode %] [% END %] [% IF ( issueloo.publicationyear ) %], [% issueloo.publicationyear %][% END %] <a href="/cgi-bin/koha/catalogue/moredetail.pl?biblionumber=[% issueloo.biblionumber %]&amp;itemnumber=[% issueloo.itemnumber %]#item[% issueloo.itemnumber %]">[% issueloo.barcode %]</a></td>
474 <td>[% UNLESS ( noItemTypeImages ) %] [% IF ( issueloo.itemtype_image ) %]<img src="[% issueloo.itemtype_image %]" alt="" />[% END %][% END %][% issueloo.itemtype_description %]</td>
475             <td>[% issueloo.issuedate %]</td>
476             <td>[% issueloo.issuingbranchname %]</td>
477                 <td>[% issueloo.itemcallnumber %]</td>
478             <td>[% issueloo.charge %]</td>
479             <td>[% issueloo.replacementprice %]</td>
480       [% IF ( issueloo.renew_failed ) %]
481             <td class="problem">Renewal Failed</td>
482       [% ELSE %]
483             <td><span style="padding: 0 1em;">[% IF ( issueloo.renewals ) %][% issueloo.renewals %][% ELSE %]0[% END %]</span>
484             [% IF ( issueloo.norenew ) %]
485                 [% IF ( issueloo.can_confirm ) %]<span class="renewals-allowed" style="display: none">
486                     <input type="checkbox" name="all_items[]" value="[% issueloo.itemnumber %]" checked="checked" style="display: none;" />
487                     [% IF ( issueloo.od ) %]
488                         <input type="checkbox" name="items[]" value="[% issueloo.itemnumber %]" checked="checked" />
489                     [% ELSE %]
490                         <input type="checkbox" name="items[]" value="[% issueloo.itemnumber %]" />
491                     [% END %]
492                     </span>
493                     <span class="renewals-disabled">
494                 [% END %]
495                 [% IF ( issueloo.norenew_reason_on_reserve ) %]
496                 <a href="/cgi-bin/koha/reserve/request.pl?biblionumber=[% issueloo.biblionumber %]">On Hold</a>
497                 [% END %]
498                                     [% IF ( issueloo.norenew_reason_too_many ) %]
499                                         Not Renewable
500                                     [% END %]
501                 [% IF ( issueloo.can_confirm ) %]
502                     </span>
503                 [% END %]
504             [% ELSE %]
505             <input type="checkbox" name="all_items[]" value="[% issueloo.itemnumber %]" checked="checked" style="display: none;" />
506             [% IF ( issueloo.red ) %]
507             <input type="checkbox" name="items[]" value="[% issueloo.itemnumber %]" checked="checked" onclick="uncheck_sibling(this);" />
508             [% ELSE %]
509             <input type="checkbox" name="items[]" value="[% issueloo.itemnumber %]" onclick="uncheck_sibling(this);" />
510             [% END %]
511             [% END %]
512             </td>
513       [% END %]
514       [% IF ( issueloo.return_failed ) %]
515             <td class="problem">Checkin Failed</td>
516       [% ELSE %]
517         [% IF ( issueloo.norenew_reason_on_reserve ) %]
518             <td><a href="/cgi-bin/koha/reserve/request.pl?biblionumber=[% issueloo.biblionumber %]">On Hold</a></td>
519         [% ELSE %]
520             <td><input type="checkbox" name="barcodes[]"  value="[% issueloo.barcode %]" onclick="uncheck_sibling(this);" />
521                 <input type="checkbox" name="all_barcodes[]" value="[% issueloo.barcode %]" checked="checked" style="display: none;" />
522             </td>
523         [% END %]
524       [% END %]
525         </tr>
526   [% END %]
527         </tbody>
528         </table>
529         <fieldset class="action">
530         [% IF ( CAN_user_circulate_override_renewals ) %]
531         [% IF ( AllowRenewalLimitOverride ) %]
532         <label for="override_limit">Override Renewal Limit:</label>
533         <input type="checkbox" name="override_limit" id="override_limit" value="1" />
534         [% END %]
535         [% END %]
536         <input type="submit" name="renew_checked" value="Renew or Return checked items" />
537         <input type="submit" id="renew_all" name="renew_all" value="Renew all" />
538         </fieldset>
539     [% ELSE %]<p>Patron has nothing checked out.</p>
540 [% END %]
541 </div>
542
543
544 [% IF relissueloop %]
545 <div id="relissues">
546  <table id="relissuest">
547     <thead>
548         <tr>
549             <th scope="col">Due date</th>
550             <th scope="col">Title</th>
551             <th scope="col">Item Type</th>
552             <th scope="col">Checked out on</th> 
553             <th scope="col">Checked out from</th>
554             <th scope="col">Call no</th>
555             <th scope="col">Charge</th>
556             <th scope="col">Price</th>
557             <th scope="col">Patron</th>
558         </tr>
559     </thead>
560        <tbody>
561        [% FOREACH relissueloo IN relissueloop %]
562
563           [% IF ( relissueloo.overdue ) %]
564           <tr class="problem">
565           [% ELSE %]
566           <tr>
567           [% END %]
568           [% IF ( relissueloo.red ) %]
569             <td class="od">
570           [% ELSE %]
571             <td>
572           [% END %]
573                 [% relissueloo.date_due %]
574                 [% IF ( relissueloo.itemlost ) %]
575                                         <span class="lost">[% relissueloo.itemlost %]</span>
576                     [% END %]
577                 [% IF ( relissueloo.damaged ) %]
578                                         <span class="dmg">[% relissueloo.itemdamaged %]</span>
579                 [% END %]
580 </td>
581             <td><a href="/cgi-bin/koha/catalogue/detail.pl?biblionumber=[% relissueloo.biblionumber %]"><strong>[% relissueloo.title |html %]</strong></a>[% IF relissueloo.author %], by [% relissueloo.author %][% END %] [% IF relissueloo.publishercode %]; [% relissueloo.publishercode %] [% END %] [% IF relissueloo.publicationyear %], [% relissueloo.publicationyear %][% END %] <a href="/cgi-bin/koha/catalogue/moredetail.pl?biblionumber=[% relissueloo.biblionumber %]&amp;itemnumber=[% relissueloo.itemnumber %]#item[% relissueloo.itemnumber %]">[% relissueloo.barcode %]</a></td>
582 <td>[% UNLESS ( noItemTypeImages ) %] [% IF ( relissueloo.itemtype_image ) %]<img src="[% relissueloo.itemtype_image %]" alt="" />[% END %][% END %][% relissueloo.itemtype_description %]</td>
583             <td>[% relissueloo.issuedate %]</td>
584             <td>[% relissueloo.issuingbranchname %]</td>
585         <td>[% relissueloo.itemcallnumber %]</td>
586         <td>[% relissueloo.charge %]</td>
587         <td>[% relissueloo.replacementprice %]</td>
588             <td><a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% relissueloo.borrowernumber %]">[% relissueloo.firstname %] [% relissueloo.surname %] ([% relissueloo.cardnumber %])</a></td>
589         </tr>
590   [% END %]
591         </tbody>
592        </table>
593         </div>
594 [% END %]
595     </form>
596         
597 <div id="onhold">
598 [% IF ( reservloop ) %]
599 <form action="/cgi-bin/koha/reserve/modrequest.pl" method="post">
600         <input type="hidden" name="from" value="borrower" />
601         <table id="holdst">
602                 <thead><tr>
603                         <th>Hold date</th>
604                         <th>Title</th>
605                         <th>Call Number</th>
606                         <th>Barcode</th>
607                         <th>Priority</th>
608                         <th>Delete?</th>
609                 </tr></thead>
610                 <tbody>[% FOREACH reservloo IN reservloop %]
611                 <tr class="[% reservloo.color %]">
612             <td>[% reservloo.reservedate %]</td>
613             <td>
614                 <a href="/cgi-bin/koha/reserve/request.pl?biblionumber=[% reservloo.biblionumber %]">[% reservloo.title |html %]</a>[% IF ( reservloo.author ) %], by [% reservloo.author %][% END %]
615             </td>
616             <td>[% reservloo.itemcallnumber %]</td>
617             <td>[% IF ( reservloo.waiting ) %]
618                 <em>Item is <strong>waiting</strong></em>
619                 [% END %]
620                 [% IF ( reservloo.transfered ) %]
621                 <em>Item <strong>in transit</strong> from
622                 [% reservloo.frombranch %] since [% reservloo.datesent %] </em>
623                 [% END %]
624
625                 [% IF ( reservloo.nottransfered ) %]
626                 <em>Item hasn't been transferred yet from [% reservloo.nottransferedby %]</em>
627                 [% END %]
628                 [% IF ( reservloo.barcodereserv ) %]
629                 <a href="/cgi-bin/koha/catalogue/detail.pl?biblionumber=[% reservloo.biblionumber %]">[% reservloo.barcodereserv %]</a>
630                 [% END %]
631             </td>
632             <td>[% IF ( reservloo.waitingposition ) %]<strong>[% reservloo.waitingposition %]</strong>[% END %]</td>
633             <td><select name="rank-request">
634                     <option value="n">No</option>
635                     <option value="del">Yes</option>
636                 </select>
637                 <input type="hidden" name="biblionumber" value="[% reservloo.biblionumber %]" />
638                 <input type="hidden" name="borrowernumber" value="[% borrowernumber %]" />
639             </td>
640         </tr>
641                 [% END %]</tbody>
642     </table>
643
644         <fieldset class="action"><input type="submit" class="cancel" name="submit" value="Cancel Marked Requests" /></fieldset>
645     </form>
646     [% ELSE %]<p>Patron has nothing on hold.</p>[% END %]
647         </div>
648
649 </div>
650 [% END %] <!-- unknowuser -->
651
652
653 </div>
654 </div>
655 <div class="yui-b">
656 [% INCLUDE 'circ-menu.inc' %]
657 </div>
658 </div>
659 [% INCLUDE 'intranet-bottom.inc' %]