4 [% USE AuthorisedValues %]
5 [% USE ColumnsSettings %]
6 [% INCLUDE 'doc-head-open.inc' %]
7 <title>Koha › Patrons ›
8 [% IF ( unknowuser ) %]
11 Patron details for [% INCLUDE 'patron-title.inc' no_html = 1 %]
14 [% INCLUDE 'doc-head-close.inc' %]
15 [% INCLUDE 'calendar.inc' %]
16 <link rel="stylesheet" type="text/css" href="[% interface %]/[% theme %]/css/datatables_[% KOHA_VERSION %].css" />
17 [% INCLUDE 'datatables.inc' %]
18 [% INCLUDE 'columns_settings.inc' %]
19 [% INCLUDE 'strings.inc' %]
20 <script type="text/javascript" src="[% interface %]/lib/jquery/plugins/jquery.checkboxes.min_[% KOHA_VERSION %].js"></script>
21 <script type="text/javascript" src="[% interface %]/lib/jquery/plugins/jquery-ui-timepicker-addon.min_[% KOHA_VERSION %].js"></script>
22 [% INCLUDE 'timepicker.inc' %]
23 <script type="text/javascript" src="[% interface %]/lib/jquery/plugins/jquery.dataTables.rowGrouping_[% KOHA_VERSION %].js"></script>
24 <script type="text/javascript" src="[% interface %]/[% theme %]/js/pages/circulation_[% KOHA_VERSION %].js"></script>
25 <script type="text/javascript" src="[% interface %]/[% theme %]/js/checkouts_[% KOHA_VERSION %].js"></script>
26 <script type="text/javascript" src="[% interface %]/[% theme %]/js/holds_[% KOHA_VERSION %].js"></script>
27 <script type="text/JavaScript">
29 /* Set some variable needed in circulation.js */
30 var interface = "[% interface %]";
31 var theme = "[% theme %]";
32 var borrowernumber = "[% borrowernumber %]";
33 var branchcode = "[% Branches.GetLoggedInBranchcode() %]";
34 var exports_enabled = "[% Koha.Preference('ExportCircHistory') %]";
35 var AllowCirculate = [% (CAN_user_circulate_circulate_remaining_permissions)? 1 : 0 %]
36 var AllowRenewalLimitOverride = [% (CAN_user_circulate_override_renewals && Koha.Preference('AllowRenewalLimitOverride') )? 1: 0 %];
37 var script = "moremember";
38 var relatives_borrowernumbers = new Array();
39 [% FOREACH b IN relatives_borrowernumbers %]
40 relatives_borrowernumbers.push("[% b %]");
43 var MSG_EXPORT_SELECT_CHECKOUTS = _("You must select checkout(s) to export");
45 columns_settings = [% ColumnsSettings.GetColumns( 'members', 'moremember', 'issues-table', 'json' ) %]
47 $(document).ready(function() {
48 if ( $('#clubs-tab').length ) {
49 $('#clubs-tab-link').on('click', function() {
50 $('#clubs-tab').text(_("Loading..."));
51 $('#clubs-tab').load('/cgi-bin/koha/clubs/patron-clubs-tab.pl?borrowernumber=[% borrowernumber %]');
55 $('#finesholdsissues').tabs({
56 // Correct table sizing for tables hidden in tabs
57 // http://www.datatables.net/examples/api/tabs_and_scrolling.html
58 "show": function(event, ui) {
59 var oTable = $('div.dataTables_wrapper>table', ui.panel).dataTable();
60 if ( oTable.length > 0 ) {
61 oTable.fnAdjustColumnSizing();
64 "activate": function( event, ui ) {
65 $('#'+ui.newTab.context.id).click();
68 $("#holdst").dataTable($.extend(true, {}, dataTablesDefaults, {
71 { "aTargets": [ -1,-2 ], "bSortable": false, "bSearchable": false }
74 { "sType": "title-string" },{ "sType": "anti-the" },null,null,null,null,null,null
79 // new YAHOO.widget.Button("delpicture"); // FIXME: formatting mismatch between YUI and normal button
80 $('#delpicture').click(function(){
81 return confirm(_("Are you sure you want to delete this patron image? This cannot be undone."));
83 $('#manage-patron-image').find("input[value*=Upload]").click(function(){
84 if($("#uploadfile").val() == ""){
85 alert(_("Please choose a file to upload"));
88 return confirm(_("Are you sure you want to replace the current patron image? This cannot be undone."));
91 $("#suspend_until").datepicker({
92 onClose: function(dateText, inst) {
93 validate_date(dateText, inst);
95 minDate: 1, // require that hold suspended until date is after today
96 }).on("change", function(e, value) {
97 if ( ! is_valid_date( $(this).val() ) ) {$(this).val("");}
100 $("#view_restrictions").on("click",function(){
101 $('#debarments-tab-link').click();
104 function uncheck_sibling(me){
105 nodename=me.getAttribute("name");
106 if (nodename =="barcodes[]"){
107 var Node=me.parentNode.previousSibling;
108 while (Node.nodeName!="TD"){Node=Node.previousSibling}
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 var Node=me.parentNode.nextSibling;
118 while (Node.nodeName!="TD"){Node=Node.nextSibling}
119 var Nodes=Node.childNodes;
120 for (var i=0;i<Nodes.length;i++){
121 if (Nodes[i].nodeName=="INPUT" && Nodes[i].getAttribute("type")=="checkbox"){
122 Nodes[i].checked=false;
127 function validate1(date) {
128 var today = new Date();
129 if ( date < today ) {
139 <body id="pat_moremember" class="pat">
140 [% INCLUDE 'header.inc' %]
141 [% INCLUDE 'patron-search.inc' %]
143 <div id="breadcrumbs">
144 <a href="/cgi-bin/koha/mainpage.pl">Home</a>
145 › <a href="/cgi-bin/koha/members/members-home.pl">Patrons</a>
146 › [% IF ( unknowuser ) %]Patron does not exist[% ELSE %]Patron details for [% INCLUDE 'patron-title.inc' %][% END %]
149 <div id="doc3" class="yui-t2">
155 [% UNLESS ( unknowuser ) %]
156 [% INCLUDE 'members-toolbar.inc' %]
160 <div class="dialog alert">
161 [% IF ( error == 'CANT_DELETE_STAFF' ) %]
162 <h3>Unable to delete staff user</h3>
163 <p>Insufficient privileges.</p>
165 [% IF ( error == 'CANT_DELETE_YOURSELF' ) %]
166 <h3>Not allowed to delete own account</h3>
167 <p>Deleting your own account would lock you out of Koha.</p>
169 [% IF ( error == 'CANT_DELETE_OTHERLIBRARY' ) %]
170 <h3>Unable to delete patrons from other libraries with current settings</h3>
171 <p>Insufficient privileges.</p>
173 [% IF ( error == 'CANT_DELETE' ) %]
174 <h3>Unable to delete patron</h3>
175 <p>Insufficient privileges.</p>
181 [% IF ( unknowuser ) %]
182 <div class="dialog message">This patron does not exist. <a href="/cgi-bin/koha/members/members-home.pl">Find another patron?</a></div>
184 [% IF ( was_renewed ) %]<div class="dialog message">Patron's account has been renewed until [% dateexpiry | $KohaDates %]</div>[% END %]
187 <div id="circmessages" class="circmessage attention">
189 [% INCLUDE 'blocked-fines.inc' %]
195 <div id="circmessages" class="circmessage attention">
197 [% IF ( userdebarred ) %]
198 <li class="blocker">Patron's account is restricted
199 [% IF ( userdebarreddate ) %]
200 until [% userdebarreddate %]
203 [% IF ( debarredcomment ) %]
204 with the explanation: <i>
205 [% IF debarredcomment.search('OVERDUES_PROCESS') %]
206 Restriction added by overdues process [% debarredcomment.remove('OVERDUES_PROCESS ') | html_line_break %]
208 [% debarredcomment | html_line_break %]
212 <a href="#reldebarments" id="view_restrictions">View restrictions</a>
215 [% IF ( gonenoaddress ) %]<li class="blocker">Patron's address is in doubt.</li>[% END %]
216 [% IF ( lost ) %]<li class="blocker">Patron's card has been reported lost.</li>[% END %]
221 <h3>[% UNLESS ( I ) %]
222 [% title | html %] [% firstname | html %] [% END %] [% surname | html %] ([% cardnumber | html %])</h3>
223 <div class="yui-u first">
224 <div id="patron-information" style="padding : .5em;">
226 [% IF ( othernames ) %]“[% othernames | html %]”[% END %]
228 <div class = "address">
229 [% IF Koha.Preference( 'AddressFormat' ) %]
230 [% INCLUDE "member-display-address-style-${ Koha.Preference( 'AddressFormat' ) }.inc" %]
232 [% INCLUDE 'member-display-address-style-us.inc' %]
238 [% IF ( phone ) %]<li><span class="label">Primary phone: </span><a href="tel:[% phone %]">[% phone | html %]</a></li>[% END %]
239 [% IF ( phonepro ) %]<li><span class="label">Secondary phone: </span><a href="tel:[% phonepro %]">[% phonepro | html %]</a></li>[% END %]
240 [% IF ( mobile ) %]<li><span class="label">Other phone: </span><a href="tel:[% mobile %]">[% mobile | html %]</a></li>[% END %]
241 [% IF ( fax ) %]<li><span class="label">Fax: </span>[% fax |html %]</li>[% END %]
242 [% IF ( email ) %]<li class="email"><span class="label">Primary email:</span><a title="[% email %]" href="mailto:[% email | url %]">[% email | html %]</a></li>[% END %]
243 [% IF ( emailpro ) %]<li class="email"><span class="label">Secondary email: </span><a title="[% emailpro %]" href="mailto:[% emailpro | url %]">[% emailpro | html %]</a></li>[% END %]
245 [% IF ( initials ) %]<li><span class="label">Initials: </span>[% initials | html %]</li>[% END %]
246 [% IF ( dateofbirth ) %]<li><span class="label">Date of birth:</span>[% dateofbirth | $KohaDates %] ([% age %] years)</li>[% END %]
247 [% IF ( sex ) %]<li><span class="label">Gender:</span>
248 [% IF ( sex == 'F' ) %]Female[% ELSIF ( sex == 'M' ) %]Male[% ELSE %][% sex %][% END %]
253 <span class="label">Guarantees:</span>
255 [% FOREACH guarantee IN guarantees %]
256 <li><a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% guarantee.borrowernumber %]">[% guarantee.firstname | html %] [% guarantee.surname | html %]</a></li>
260 [% ELSIF guarantor %]
262 <span class="label">Guarantor:</span>
263 [% IF guarantor.borrowernumber %]
264 <a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% guarantor.borrowernumber %]">[% guarantor.firstname | html %] [% guarantor.surname | html %]</a>
266 [% guarantor.firstname | html %] [% guarantor.surname | html %]
273 [% IF ( guarantor.borrowernumber ) %]
274 <a href="memberentry.pl?op=modify&borrowernumber=[% borrowernumber %]&step=1&guarantorid=[% guarantor.borrowernumber %]">Edit</a>
276 <a href="memberentry.pl?op=modify&borrowernumber=[% borrowernumber %]&step=1">Edit</a>
281 <!-- Begin Upload Patron Image Section -->
283 <div id="manage-patron-image">
284 [% IF ( patronimages ) %]
285 [% IF ( CAN_user_tools_batch_upload_patron_images ) %]
286 <form method="post" action="/cgi-bin/koha/tools/picture-upload.pl" enctype="multipart/form-data">
287 <fieldset class="brief">
289 <legend>Manage patron image</legend>
290 <div class="hint">To update the image for [% title | html %] [% surname | html %], select a new image file and click 'Upload.' <br />Click the 'Delete' button to remove the current image.
292 <legend>Upload patron image</legend>
293 <div class="hint">[% title %] [% firstname | html %] [% surname | html %] does not currently have an image available. To import an image for [% title %] [% surname | html %], enter the name of an image file to upload.
295 <br />Only PNG, GIF, JPEG, XPM formats are supported.
297 <input type="hidden" id="image" name="filetype" value="image" />
298 <input type="hidden" id="cardnumber" name="cardnumber" value="[% cardnumber | html %]" />
299 <input type="hidden" name="borrowernumber" value="[% borrowernumber %]" />
302 <label for="uploadfile">Select the file to upload: </label><input type="file" id="uploadfile" name="uploadfile" />
305 <fieldset class="action">
306 <input type="hidden" name="csrf_token" value="[% csrf_token %]" />
307 <input type="submit" value="Upload" class="submit" />
308 <input name="op" type="hidden" value="Upload" />
309 [% IF ( picture ) %]<a id="delpicture" href="/cgi-bin/koha/tools/picture-upload.pl?op=Delete&borrowernumber=[% borrowernumber %]&csrf_token=[% csrf_token %]" class="delete">Delete</a>[% END %]
317 <!-- End Upload Patron Image Section -->
319 [% IF Koha.Preference('HouseboundModule') %]
320 <div id="houseboundroles">
321 <h3>Housebound roles</h3>
325 <span class="label">Chooser:</span>
326 [% IF ( housebound_role.housebound_chooser == 1 ) %]
333 <span class="label">Deliverer:</span>
334 [% IF ( housebound_role.housebound_deliverer == 1 ) %]
343 <div class="action"><a href="memberentry.pl?op=modify&borrowernumber=[% borrowernumber %]&step=4">Edit</a></div>
346 [% IF ( ExtendedPatronAttributes ) %]
347 [% UNLESS ( no_patron_attribute_types ) %]
348 <div id="patron-extended-attributes" style="padding-top: 1em;">
349 <h3>Additional attributes and identifiers</h3>
350 [% FOREACH attribute IN attributes_loop %]
351 [% IF attribute.class %]
352 <div id="aai_[% attribute.class %]" class="rows">
354 <div id="aai" class="rows">
356 <h4>[% attribute.lib %]</h4>
358 [% FOREACH item IN attribute.items %]
360 <span class="label">[% item.description %]: </span>
361 [% IF ( item.value_description ) %]
362 [% item.value_description %]
364 [% item.value| html_line_break %]
372 <div class="action"><a href="memberentry.pl?op=modify&borrowernumber=[% borrowernumber %]&step=4">Edit</a></div>
377 [% IF ( EnhancedMessagingPreferences ) %]
378 <div id="patron-messaging-prefs" style="padding-top: 1em;">
379 <h3>Patron messaging preferences</h3>
380 [% INCLUDE 'messaging-preference-form.inc' %]
381 [% IF ( SMSSendDriver ) %]
382 <div class="rows"> <ol><li><span class="label">SMS number:</span><a href="sms:[% SMSnumber %]">[% SMSnumber %]</a>
386 <div class="action"><a href="memberentry.pl?op=modify&borrowernumber=[% borrowernumber %]&step=5">Edit</a></div>
391 <div id="patron-library-details">
395 <li><span class="label">Card number: </span>[% cardnumber %]</li>
396 <li><span class="label">Borrowernumber: </span> [% borrowernumber %]</li>
397 <li><span class="label">Category: </span>[% categoryname %] ([% categorycode %])</li>
398 <li><span class="label">Registration date: </span>[% dateenrolled | $KohaDates %]</li>
400 <li><span class="label">Expiration date: </span>
401 [% IF ( was_renewed ) %]
402 <strong class="reregistrinfo">[% dateexpiry | $KohaDates %]</strong>
404 [% dateexpiry | $KohaDates %]
408 <li><span class="label">Library: </span>[% branchname %]</li>
410 [% IF ( OPACPrivacy ) %]<li><span class="label">Privacy Pref:</span>
411 [% IF ( privacy0 ) %]Forever[% END %]
412 [% IF ( privacy1 ) %]Default[% END %]
413 [% IF ( privacy2 ) %]Never[% END %]
417 <span class="label">Show checkouts to guarantor</span>
418 [% IF privacy_guarantor_checkouts %]
425 [% IF ( sort1 ) %]<li><span class="label">Sort field 1:</span>[% AuthorisedValues.GetByCode('Bsort1', sort1) |html %]</li>[% END %]
426 [% IF ( sort2 ) %]<li><span class="label">Sort field 2:</span>[% AuthorisedValues.GetByCode('Bsort2', sort2) |html %]</li>[% END %]
427 <li><span class="label">Username: </span>[% userid |html %]</li>
428 <li><span class="label">Password: </span>
429 [% IF ( password ) %]
432 <span class="problem"><a href="/cgi-bin/koha/members/member-password.pl?member=[% borrowernumber %]">Undefined</a></span>
435 [% IF ( borrowernotes ) %]<li><span class="label">Circulation note: </span>[% borrowernotes |html %]</li>[% END %]
436 [% IF ( opacnote ) %]<li><span class="label">OPAC note:</span>[% opacnote |html %]</li>[% END %]
437 [% IF Koha.Preference( 'NorwegianPatronDBEnable' ) == 1 %]
438 [% IF ( sync == 1 ) %]
439 <li><span class="label">Activate sync: </span>Yes</li>
440 [% IF ( syncstatus ) %]<li><span class="label">Sync status: </span>[% syncstatus %]</li>[% END %]
441 [% IF ( lastsync ) %]<li><span class="label">Last sync: </span>[% lastsync | $KohaDates %]</li>[% END %]
443 <li><span class="label">Activate sync: </span>No</li>
446 [% IF ( Koha.Preference('CheckPrevCheckout') == 'softyes' || Koha.Preference('CheckPrevCheckout') == 'softno' ) %]
447 <li><span class="label">Check previous checkouts: </span>
448 [% IF ( checkprevcheckout == 'yes' ) %]
450 [% ELSIF ( checkprevcheckout == 'no' ) %]
457 [% IF Koha.Preference('TranslateNotices') %]
459 <span class="label">Preferred language for notices: </span>
460 [% translated_language %]
466 <div class="action"><a href="memberentry.pl?op=modify&borrowernumber=[% borrowernumber %]&step=3">Edit</a></div>
468 <div id="patron-alternate-address" style="padding-top: 1em;">
469 <h3>Alternate address</h3>
471 [% IF Koha.Preference( 'AddressFormat' ) %]
472 [% INCLUDE "member-display-alt-address-style-${ Koha.Preference( 'AddressFormat' ) }.inc" %]
474 [% INCLUDE 'member-display-alt-address-style-us.inc' %]
477 <div class="rows"> <ol>
478 [% IF ( B_phone ) %]<li><span class="label">Phone: </span><a href="tel:[% B_phone %]">[% B_phone |html %]</a></li>[% END %]
479 [% IF ( B_email ) %]<li class="email"><span class="label">Email: </span><a title="[% B_email %]" href="mailto:[% B_email | url %]">[% B_email |html %]</a></li>[% END %]
480 [% IF ( contactnote ) %]<li><span class="label">Contact note: </span> [% contactnote |html %]</li>[% END %]
484 <div class="action"><a href="memberentry.pl?op=modify&borrowernumber=[% borrowernumber %]&step=6">Edit</a></div>
486 <div id="patron-alternative-contact" style="padding-top: 1em;">
487 <h3>Alternative contact</h3>
488 <div class="rows"> <ol><li><span class="label">Surname: </span>[% altcontactsurname | html %]</li>
489 <li><span class="label">First name: </span>[% altcontactfirstname | html %]</li>
490 <li><span class="label">Address: </span>[% altcontactaddress1 | html %]</li>
491 <li><span class="label">Address 2: </span>[% altcontactaddress2 | html %]</li>
492 <li><span class="label">City: </span>[% altcontactaddress3 | html %]</li>
493 [% IF ( altcontactstate ) %]<li><span class="label">State: </span>[% altcontactstate | html %]</li>[% END %]
494 <li><span class="label">ZIP/Postal code: </span>[% altcontactzipcode | html %]</li>
495 [% IF ( altcontactcountry ) %]<li><span class="label">Country: </span>[% altcontactcountry | html %]</li>[% END %]
496 [% IF ( altcontactphone ) %]<li><span class="label">Phone: </span><a href="tel:[% altcontactphone | url %]">[% altcontactphone | html %]</a></li>[% END %]
499 <div class="action"><a href="memberentry.pl?op=modify&borrowernumber=[% borrowernumber %]&step=2">Edit</a></div>
504 <div id="finesholdsissues" class="toptabs">
506 <li><a href="#checkouts">[% issuecount %] Checkout(s)</a></li>
507 [% IF relatives_issues_count %]
508 <li><a href="#relatives-issues" id="relatives-issues-tab">Relatives' checkouts</a></li>
510 <li><a href="#finesandcharges">Fines & Charges</a></li>
512 [% IF ( holds_count ) %]
513 <a href="#reserves" id="holds-tab">[% holds_count %] Hold(s)</a>
515 <a href="#reserves" id="holds-tab">0 Holds</a>
518 [% IF Koha.Preference('ArticleRequests') %]
520 <a href="#article-requests" id="article-requests-tab"> [% patron.article_requests_current.count %] Article requests</a>
523 <li><a id="debarments-tab-link" href="#reldebarments">[% debarments.size %] Restrictions</a></li>
525 [% SET enrollments = patron.get_club_enrollments(1) %]
526 [% SET enrollable = patron.get_enrollable_clubs(0,1) %]
527 [% IF CAN_user_clubs && ( enrollable.count || enrollments.count ) %]
529 <a id="clubs-tab-link" href="#clubs-tab">
530 Clubs ([% enrollments.count %]/[% enrollable.count %])
536 [% INCLUDE "checkouts-table.inc" %]
538 [% IF ( relatives_issues_count ) %]
539 <div id="relatives-issues">
540 <table id="relatives-issues-table" style="width: 100% !Important;">
543 <th scope="col">Due date hidden not formatted</th>
544 <th scope="col">Due date</th>
545 <th scope="col">Title</th>
546 <th scope="col">Item type</th>
547 <th scope="col">Location</th>
548 <th scope="col">Checked out on</th>
549 <th scope="col">Checked out from</th>
550 <th scope="col">Call no</th>
551 <th scope="col">Charge</th>
552 <th scope="col">Fine</th>
553 <th scope="col">Price</th>
554 <th scope="col">Patron</th>
561 <div id="finesandcharges">
562 [% IF ( totaldue_raw ) %]
563 <p>Total due: [% totaldue %]</p>
565 <p>No outstanding charges</p>
569 [% IF CAN_user_clubs && ( enrollments.count || enrollable.count ) %]
575 [% INCLUDE borrower_debarments.inc %]
578 [% IF ( holds_count ) %]
579 <form action="/cgi-bin/koha/reserve/modrequest.pl" method="post">
580 <input type="hidden" name="from" value="circ" />
581 <table id="holds-table" style="width: 100% !Important;">
597 <fieldset class="action">
598 <input type="submit" class="cancel" name="submit" value="Cancel marked holds" />
602 [% IF Koha.Preference('SuspendHoldsIntranet') %]
603 <fieldset class="action">
604 <form action="/cgi-bin/koha/reserve/modrequest_suspendall.pl" method="post">
605 <input type="hidden" name="from" value="borrower" />
606 <input type="hidden" name="borrowernumber" value="[% borrowernumber %]" />
607 <input type="submit" value="Suspend all holds" />
609 [% IF Koha.Preference('AutoResumeSuspendedHolds') %]
610 <label for="suspend_until">until</label>
611 <input type="text" size="10" id="suspend_until" name="suspend_until" class="datepicker"/>
612 <span class="hint">Specify date on which to resume [% INCLUDE 'date-format.inc' %]: </span>
617 <fieldset class="action">
618 <form action="/cgi-bin/koha/reserve/modrequest_suspendall.pl" method="post">
619 <input type="hidden" name="from" value="borrower" />
620 <input type="hidden" name="borrowernumber" value="[% borrowernumber %]" />
621 <input type="hidden" name="suspend" value="0" />
622 <input type="submit" value="Resume all suspended holds" />
625 [% END # IF SuspendHoldsIntranet %]
627 [% ELSE %]<p>Patron has nothing on hold.</p>[% END %]
631 [% IF Koha.Preference('ArticleRequests') %]
632 [% INCLUDE 'patron-article-requests.inc' %]
636 [% END %] <!-- unknowuser -->
642 [% INCLUDE 'circ-menu.inc' %]
645 [% INCLUDE 'intranet-bottom.inc' %]