3 [% USE AuthorisedValues %]
4 [% USE ColumnsSettings %]
5 [% IF Koha.Preference('ExportRemoveFields') OR Koha.Preference('ExportWithCsvProfile') %]
6 [% SET exports_enabled = 1 %]
8 [% INCLUDE 'doc-head-open.inc' %]
9 <title>Koha › Patrons ›
10 [% IF ( unknowuser ) %]
13 Patron details for [% INCLUDE 'patron-title.inc' %]
16 [% INCLUDE 'doc-head-close.inc' %]
17 [% INCLUDE 'calendar.inc' %]
18 <link rel="stylesheet" type="text/css" href="[% interface %]/[% theme %]/en/css/datatables.css" />
19 [% INCLUDE 'datatables.inc' %]
20 [% INCLUDE 'columns_settings.inc' %]
21 [% INCLUDE 'strings.inc' %]
22 <script type="text/javascript" src="[% interface %]/lib/jquery/plugins/jquery.checkboxes.min.js"></script>
23 <script type="text/javascript" src="[% interface %]/lib/jquery/plugins/jquery-ui-timepicker-addon.min.js"></script>
24 [% INCLUDE 'timepicker.inc' %]
25 <script type="text/javascript" src="[% interface %]/lib/jquery/plugins/jquery.dataTables.rowGrouping.js"></script>
26 <script type="text/javascript" src="[% themelang %]/js/pages/circulation.js"></script>
27 <script type="text/javascript" src="[% themelang %]/js/checkouts.js"></script>
28 <script type="text/javascript" src="[% themelang %]/js/holds.js"></script>
29 <script type="text/JavaScript">
31 /* Set some variable needed in circulation.js */
32 var interface = "[% interface %]";
33 var theme = "[% theme %]";
34 var borrowernumber = "[% borrowernumber %]";
35 var branchcode = "[% branch %]";
36 var exports_enabled = "[% exports_enabled %]";
37 var AllowCirculate = [% (CAN_user_circulate_circulate_remaining_permissions)? 1 : 0 %]
38 var AllowRenewalLimitOverride = [% (CAN_user_circulate_override_renewals && AllowRenewalLimitOverride)? 1: 0 %];
39 var script = "moremember";
40 var relatives_borrowernumbers = new Array();
41 [% FOREACH b IN relatives_borrowernumbers %]
42 relatives_borrowernumbers.push("[% b %]");
45 var MSG_ADD_MESSAGE = _("Add a new message");
46 var MSG_EXPORT_SELECT_CHECKOUTS = _("You must select checkout(s) to export");
48 columns_settings = [% ColumnsSettings.GetColumns( 'members', 'moremember', 'issues-table', 'json' ) %]
50 $(document).ready(function() {
51 $('#finesholdsissues').tabs({
52 // Correct table sizing for tables hidden in tabs
53 // http://www.datatables.net/examples/api/tabs_and_scrolling.html
54 "show": function(event, ui) {
55 var oTable = $('div.dataTables_wrapper>table', ui.panel).dataTable();
56 if ( oTable.length > 0 ) {
57 oTable.fnAdjustColumnSizing();
60 "activate": function( event, ui ) {
61 $('#'+ui.newTab.context.id).click();
64 $("#holdst").dataTable($.extend(true, {}, dataTablesDefaults, {
67 { "aTargets": [ -1,-2 ], "bSortable": false, "bSearchable": false }
70 { "sType": "title-string" },{ "sType": "anti-the" },null,null,null,null,null,null
75 // new YAHOO.widget.Button("delpicture"); // FIXME: formatting mismatch between YUI and normal button
76 $('#delpicture').click(function(){
77 return confirm(_("Are you sure you want to delete this patron image? This cannot be undone."));
79 $('#manage-patron-image').find("input[value*=Upload]").click(function(){
80 if($("#uploadfile").val() == ""){
81 alert(_("Please choose a file to upload"));
84 return confirm(_("Are you sure you want to replace the current patron image? This cannot be undone."));
87 $("#suspend_until").datepicker({ minDate: 1 }); // require that hold suspended until date is after today
88 $("#newduedate").datetimepicker({
89 minDate: 1, // require that renewal date is after today
94 function uncheck_sibling(me){
95 nodename=me.getAttribute("name");
96 if (nodename =="barcodes[]"){
97 var Node=me.parentNode.previousSibling;
98 while (Node.nodeName!="TD"){Node=Node.previousSibling}
99 var Nodes=Node.childNodes;
100 for (var i=0;i < Nodes.length;i++){
101 if (Nodes[i].nodeName=="INPUT" && Nodes[i].getAttribute("type")=="checkbox"){
102 Nodes[i].checked=false;
107 var Node=me.parentNode.nextSibling;
108 while (Node.nodeName!="TD"){Node=Node.nextSibling}
109 var Nodes=Node.childNodes;
110 for (var i=0;i<Nodes.length;i++){
111 if (Nodes[i].nodeName=="INPUT" && Nodes[i].getAttribute("type")=="checkbox"){
112 Nodes[i].checked=false;
117 function validate1(date) {
118 var today = new Date();
119 if ( date < today ) {
129 <body id="pat_moremember" class="pat">
130 [% INCLUDE 'header.inc' %]
131 [% INCLUDE 'patron-search.inc' %]
133 <div id="breadcrumbs">
134 <a href="/cgi-bin/koha/mainpage.pl">Home</a>
135 › <a href="/cgi-bin/koha/members/members-home.pl">Patrons</a>
136 › [% IF ( unknowuser ) %]Patron does not exist[% ELSE %]Patron details for [% INCLUDE 'patron-title.inc' %][% END %]
139 <div id="doc3" class="yui-t1">
144 [% INCLUDE 'members-toolbar.inc' %]
147 <div class="dialog alert">
148 [% IF ( error == 'CANT_DELETE_STAFF' ) %]
149 <h3>Unable to delete staff user</h3>
150 <p>Insufficient privileges.</p>
152 [% IF ( error == 'CANT_DELETE_YOURSELF' ) %]
153 <h3>Not allowed to delete own account</h3>
154 <p>Deleting your own account would lock you out of Koha.</p>
156 [% IF ( error == 'CANT_DELETE_OTHERLIBRARY' ) %]
157 <h3>Unable to delete patrons from other libraries with current settings</h3>
158 <p>Insufficient privileges.</p>
160 [% IF ( error == 'CANT_DELETE' ) %]
161 <h3>Unable to delete patron</h3>
162 <p>Insufficient privileges.</p>
168 [% IF ( unknowuser ) %]
169 <div class="dialog message">This patron does not exist.</div>
171 [% IF ( was_renewed ) %]<div class="dialog message">Patron's account has been renewed until [% dateexpiry | $KohaDates %]</div>[% END %]
174 <div id="circmessages" class="circmessage attention">
176 [% IF ( userdebarred ) %]
177 <li class="blocker">Patron's account is restricted
178 [% IF ( userdebarreddate ) %]
179 until [% userdebarreddate %]
182 [% IF ( debarredcomment ) %]
183 with the explanation: <i>[% debarredcomment | html_line_break %]</i>
185 <a href="#reldebarments" onclick="$('#debarments-tab-link').click()">View restrictions</a>
188 [% IF ( gonenoaddress ) %]<li class="blocker">Patron's address is in doubt.</li>[% END %]
189 [% IF ( lost ) %]<li class="blocker">Patron's card has been reported lost.</li>[% END %]
194 <h3>[% UNLESS ( I ) %]
195 [% title %] [% firstname %] [% END %] [% surname %] ([% cardnumber %])</h3>
196 <div class="yui-u first">
197 <div id="patron-information" style="padding : .5em;">
199 [% UNLESS ( I ) %][% IF ( othernames ) %]“[% othernames %]”[% END %]
201 <div class = "address">
202 [% IF Koha.Preference( 'AddressFormat' ) %]
203 [% INCLUDE "member-display-address-style-${ Koha.Preference( 'AddressFormat' ) }.inc" %]
205 [% INCLUDE 'member-display-address-style-us.inc' %]
212 [% IF ( phonepro ) %]<li><span class="label">Organization phone: </span>[% phonepro %]</li>[% END %]
213 [% IF ( emailpro ) %]<li><span class="label">Organization email: </span>[% emailpro %]</li>[% END %]
215 [% IF ( phone ) %]<li><span class="label">Primary phone: </span>[% phone %]</li>[% END %]
216 [% IF ( phonepro ) %]<li><span class="label">Secondary phone: </span>[% phonepro %]</li>[% END %]
217 [% IF ( mobile ) %]<li><span class="label">Other phone: </span>[% mobile %]</li>[% END %]
221 [% IF ( phone ) %]<li><span class="label">Primary phone: </span>[% phone %]</li>[% END %]
222 [% IF ( mobile ) %]<li><span class="label">Other phone: </span>[% mobile %]</li>[% END %]
224 [% IF ( fax ) %]<li><span class="label">Fax: </span>[% fax %]</li>[% END %]
226 [% IF ( email ) %]<li><span class="label">Primary email:</span><a href="mailto:[% email %]">[% email %]</a></li>[% END %]
227 [% IF ( emailpro ) %]<li><span class="label">Secondary email: </span><a href="mailto:[% emailpro %]">[% emailpro %]</a></li>[% END %]
229 [% IF ( initials ) %]<li><span class="label">Initials: </span>[% initials %]</li>[% END %]
230 [% IF ( dateofbirth ) %]<li><span class="label">Date of birth:</span>[% dateofbirth | $KohaDates %] ([% age %] years)</li>[% END %]
231 [% IF ( sex ) %]<li><span class="label">Gender:</span>
232 [% IF ( sex == 'F' ) %]Female[% ELSIF ( sex == 'M' ) %]Male[% ELSE %][% sex %][% END %]
233 </li>[% END %][% END %]
234 [% IF ( isguarantee ) %]
235 [% IF ( guaranteeloop ) %]
236 <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>
239 [% IF ( guarantorborrowernumber ) %]
240 <li><span class="label">Guarantor:</span><a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% guarantorborrowernumber %]">[% guarantorsurname %][%IF ( guarantorfirstname ) %], [% guarantorfirstname %] [% END %]</a></li>
246 [% IF ( guarantorborrowernumber ) %]
247 <a href="memberentry.pl?op=modify&borrowernumber=[% borrowernumber %]&step=1&guarantorid=[% guarantorborrowernumber %]">Edit</a>
249 <a href="memberentry.pl?op=modify&borrowernumber=[% borrowernumber %]&step=1">Edit</a>
254 <!-- Begin Upload Patron Image Section -->
256 <div id="manage-patron-image">
257 [% IF ( patronimages ) %]
258 [% IF ( CAN_user_tools_batch_upload_patron_images ) %]
259 <form method="post" action="/cgi-bin/koha/tools/picture-upload.pl" enctype="multipart/form-data">
260 <fieldset class="brief">
262 <legend>Manage Patron Image</legend>
263 <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.
265 <legend>Upload Patron Image</legend>
266 <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.
268 <br />Only PNG, GIF, JPEG, XPM formats are supported.
270 <input type="hidden" id="image" name="filetype" value="image" />
271 <input type="hidden" id="cardnumber" name="cardnumber" value="[% cardnumber %]" />
272 <input type="hidden" name="borrowernumber" value="[% borrowernumber %]" />
275 <label for="uploadfile">Select the file to upload: </label><input type="file" id="uploadfile" name="uploadfile" />
278 <fieldset class="action">
279 <input type="submit" value="Upload" class="submit" />
280 <input name="op" type="hidden" value="Upload" />
281 [% IF ( picture ) %]<a id="delpicture" href="/cgi-bin/koha/tools/picture-upload.pl?op=Delete&borrowernumber=[% borrowernumber %]" class="delete">Delete</a>[% END %]
289 <!-- End Upload Patron Image Section -->
291 [% IF ( ExtendedPatronAttributes ) %]
292 [% UNLESS ( no_patron_attribute_types ) %]
293 <div id="patron-extended-attributes" style="padding-top: 1em;">
294 <h3>Additional attributes and identifiers</h3>
295 [% FOREACH attribute IN attributes_loop %]
296 [% IF attribute.class %]
297 <div id="aai_[% attribute.class %]" class="rows">
299 <div id="aai" class="rows">
301 <h4>[% attribute.lib %]</h4>
303 [% FOREACH item IN attribute.items %]
305 <span class="label">[% item.description %]: </span>
306 [% IF ( item.value_description ) %]
307 [% item.value_description %]
309 [% item.value| html_line_break %]
317 <div class="action"><a href="memberentry.pl?op=modify&borrowernumber=[% borrowernumber %]&step=4">Edit</a></div>
321 [% IF ( EnhancedMessagingPreferences ) %]
322 <div id="patron-messaging-prefs" style="padding-top: 1em;">
323 <h3>Patron messaging preferences</h3>
324 [% INCLUDE 'messaging-preference-form.inc' %]
325 [% IF ( SMSSendDriver ) %]
326 <div class="rows"> <ol><li><span class="label">SMS number:</span>[% SMSnumber %]
330 <div class="action"><a href="memberentry.pl?op=modify&borrowernumber=[% borrowernumber %]&step=5">Edit</a></div>
335 <div id="patron-library-details">
339 <li><span class="label">Card number: </span>[% cardnumber %]</li>
340 <li><span class="label">Borrowernumber: </span> [% borrowernumber %]</li>
341 <li><span class="label">Category: </span>[% description %] ([% categorycode %])</li>
342 <li><span class="label">Registration date: </span>[% dateenrolled | $KohaDates %]</li>
344 <li><span class="label">Expiration date: </span>
345 [% IF ( was_renewed ) %]
346 <strong class="reregistrinfo">[% dateexpiry | $KohaDates %]</strong>
348 [% dateexpiry | $KohaDates %]
352 <li><span class="label">Library: </span>[% branchname %]</li>
354 [% IF ( OPACPrivacy ) %]<li><span class="label">Privacy Pref:</span>
355 [% IF ( privacy0 ) %]Forever[% END %]
356 [% IF ( privacy1 ) %]Default[% END %]
357 [% IF ( privacy2 ) %]Never[% END %]
361 <span class="label">Show checkouts to guarantor</span>
362 [% IF privacy_guarantor_checkouts %]
369 [% IF ( sort1 ) %]<li><span class="label">Sort field 1:</span>[% lib1 %]</li>[% END %]
370 [% IF ( sort2 ) %]<li><span class="label">Sort field 2:</span>[% lib2 %]</li>[% END %]
371 <li><span class="label">Username: </span>[% userid %]</li>
372 <li><span class="label">Password: </span>
373 [% IF ( password ) %]
376 <span class="problem"><a href="/cgi-bin/koha/members/member-password.pl?member=[% borrowernumber %]">Undefined</a></span>
379 [% IF ( borrowernotes ) %]<li><span class="label">Circulation note: </span>[% borrowernotes %]</li>[% END %]
380 [% IF ( opacnote ) %]<li><span class="label">OPAC note:</span>[% opacnote %]</li>[% END %]
381 [% IF Koha.Preference( 'NorwegianPatronDBEnable' ) == 1 %]
382 [% IF ( sync == 1 ) %]
383 <li><span class="label">Activate sync: </span>Yes</li>
384 [% IF ( syncstatus ) %]<li><span class="label">Sync status: </span>[% syncstatus %]</li>[% END %]
385 [% IF ( lastsync ) %]<li><span class="label">Last sync: </span>[% lastsync | $KohaDates %]</li>[% END %]
387 <li><span class="label">Activate sync: </span>No</li>
393 <div class="action"><a href="memberentry.pl?op=modify&borrowernumber=[% borrowernumber %]&step=3">Edit</a></div>
396 <div id="patron-alternate-address" style="padding-top: 1em;">
397 <h3>Alternate address</h3>
398 <div class="rows"> <ol><li><span class="label">Address: </span>[% B_address %]</li>
399 <li><span class="label">Address 2: </span>[% B_address2 %]</li>
400 <li><span class="label">City: </span>[% B_city %]</li>
401 [% IF ( B_state ) %]<li><span class="label">State: </span>[% B_state %]</li>[% END %]
402 <li><span class="label">ZIP/Postal code: </span>[% B_zipcode %]</li>
403 [% IF ( B_country ) %]<li><span class="label">Country: </span>[% B_country %]</li>[% END %]
404 [% IF ( B_phone ) %]<li><span class="label">Phone: </span>[% B_phone %]</li>[% END %]
405 [% IF ( B_email ) %]<li><span class="label">Email: </span><a href="mailto:[% B_email %]">[% B_email %]</a></li>[% END %]
406 [% IF ( contactnote ) %]<li><span class="label">Contact note: </span> [% contactnote %]</li>[% END %]
410 <div class="action"><a href="memberentry.pl?op=modify&borrowernumber=[% borrowernumber %]&step=6">Edit</a></div>
413 <div id="patron-alternative-contact" style="padding-top: 1em;">
414 <h3>Alternative contact</h3>
415 <div class="rows"> <ol><li><span class="label">Surname: </span>[% altcontactsurname %]</li>
416 <li><span class="label">First name: </span>[% altcontactfirstname %]</li>
417 <li><span class="label">Address: </span>[% altcontactaddress1 %]</li>
418 <li><span class="label">Address 2: </span>[% altcontactaddress2 %]</li>
419 <li><span class="label">City: </span>[% altcontactaddress3 %]</li>
420 [% IF ( altcontactstate ) %]<li><span class="label">State: </span>[% altcontactstate %]</li>[% END %]
421 <li><span class="label">ZIP/Postal code: </span>[% altcontactzipcode %]</li>
422 [% IF ( altcontactcountry ) %]<li><span class="label">Country: </span>[% altcontactcountry %]</li>[% END %]
423 [% IF ( altcontactphone ) %]<li><span class="label">Phone: </span>[% altcontactphone %]</li>[% END %]
426 <div class="action"><a href="memberentry.pl?op=modify&borrowernumber=[% borrowernumber %]&step=2">Edit</a></div>
431 <div id="finesholdsissues" class="toptabs">
433 <li><a href="#checkouts">[% issuecount %] Checkout(s)</a></li>
434 [% IF relatives_issues_count %]
435 <li><a href="#relatives-issues" id="relatives-issues-tab">Relatives' checkouts</a></li>
437 <li><a href="#finesandcharges">Fines & Charges</a></li>
439 [% IF ( holds_count ) %]
440 <a href="#reserves" id="holds-tab">[% holds_count %] Hold(s)</a>
442 <a href="#reserves" id="holds-tab">0 Holds</a>
445 <li><a id="debarments-tab-link" href="#reldebarments">[% debarments.size %] Restrictions</a></li>
448 [% INCLUDE "checkouts-table.inc" %]
450 [% IF ( relatives_issues_count ) %]
451 <div id="relatives-issues">
452 <table id="relatives-issues-table" style="width: 100% !Important;">
455 <th scope="col">Due date hidden not formatted</th>
456 <th scope="col">Due date</th>
457 <th scope="col">Title</th>
458 <th scope="col">Item type</th>
459 <th scope="col">Location</th>
460 <th scope="col">Checked out on</th>
461 <th scope="col">Checked out from</th>
462 <th scope="col">Call no</th>
463 <th scope="col">Charge</th>
464 <th scope="col">Fine</th>
465 <th scope="col">Price</th>
466 <th scope="col">Patron</th>
473 <div id="finesandcharges">
474 [% IF ( totaldue_raw ) %]
475 <p>Total due: [% totaldue %]</p>
477 <p>No outstanding charges</p>
481 [% INCLUDE borrower_debarments.inc %]
484 [% IF ( holds_count ) %]
485 <form action="/cgi-bin/koha/reserve/modrequest.pl" method="post">
486 <input type="hidden" name="from" value="circ" />
487 <table id="holds-table" style="width: 100% !Important;">
503 <fieldset class="action">
504 <input type="submit" class="cancel" name="submit" value="Cancel marked holds" />
508 [% IF SuspendHoldsIntranet %]
509 <fieldset class="action">
510 <form action="/cgi-bin/koha/reserve/modrequest_suspendall.pl" method="post">
511 <input type="hidden" name="from" value="borrower" />
512 <input type="hidden" name="borrowernumber" value="[% borrowernumber %]" />
513 <input type="submit" value="Suspend all holds" />
515 [% IF AutoResumeSuspendedHolds %]
516 <label for="suspend_until">until</label>
517 <input type="text" size="10" id="suspend_until" name="suspend_until"/>
518 <span class="hint">Specify date on which to resume [% INCLUDE 'date-format.inc' %]: </span>
523 <fieldset class="action">
524 <form action="/cgi-bin/koha/reserve/modrequest_suspendall.pl" method="post">
525 <input type="hidden" name="from" value="borrower" />
526 <input type="hidden" name="borrowernumber" value="[% borrowernumber %]" />
527 <input type="hidden" name="suspend" value="0" />
528 <input type="submit" value="Resume all suspended holds" />
531 [% END # IF SuspendHoldsIntranet %]
533 [% ELSE %]<p>Patron has nothing on hold.</p>[% END %]
537 [% END %] <!-- unknowuser -->
543 [% INCLUDE 'circ-menu.inc' %]
546 [% INCLUDE 'intranet-bottom.inc' %]