3 [% USE ColumnsSettings %]
4 [% IF Koha.Preference('ExportRemoveFields') OR Koha.Preference('ExportWithCsvProfile') %]
5 [% SET exports_enabled = 1 %]
7 [% INCLUDE 'doc-head-open.inc' %]
8 <title>Koha › Patrons ›
9 [% IF ( unknowuser ) %]
12 Patron details for [% INCLUDE 'patron-title.inc' %]
15 [% INCLUDE 'doc-head-close.inc' %]
16 [% INCLUDE 'calendar.inc' %]
17 <link rel="stylesheet" type="text/css" href="[% interface %]/[% theme %]/en/css/datatables.css" />
18 [% INCLUDE 'datatables.inc' %]
19 [% INCLUDE 'columns_settings.inc' %]
20 [% INCLUDE 'strings.inc' %]
21 <script type="text/javascript" src="[% interface %]/lib/jquery/plugins/jquery.checkboxes.min.js"></script>
22 <script type="text/javascript" src="[% interface %]/lib/jquery/plugins/jquery-ui-timepicker-addon.min.js"></script>
23 [% INCLUDE 'timepicker.inc' %]
24 <script type="text/javascript" src="[% interface %]/lib/jquery/plugins/jquery.dataTables.rowGrouping.js"></script>
25 <script type="text/javascript" src="[% themelang %]/js/pages/circulation.js"></script>
26 <script type="text/javascript" src="[% themelang %]/js/checkouts.js"></script>
27 <script type="text/javascript" src="[% themelang %]/js/holds.js"></script>
28 <script type="text/JavaScript">
30 /* Set some variable needed in circulation.js */
31 var interface = "[% interface %]";
32 var theme = "[% theme %]";
33 var borrowernumber = "[% borrowernumber %]";
34 var branchcode = "[% branch %]";
35 var exports_enabled = "[% exports_enabled %]";
36 var AllowCirculate = [% (CAN_user_circulate_circulate_remaining_permissions)? 1 : 0 %]
37 var AllowRenewalLimitOverride = [% (CAN_user_circulate_override_renewals && AllowRenewalLimitOverride)? 1: 0 %];
38 var script = "moremember";
39 var relatives_borrowernumbers = new Array();
40 [% FOREACH b IN relatives_borrowernumbers %]
41 relatives_borrowernumbers.push("[% b %]");
44 var MSG_ADD_MESSAGE = _("Add a new message");
45 var MSG_EXPORT_SELECT_CHECKOUTS = _("You must select checkout(s) to export");
47 columns_settings = [% ColumnsSettings.GetColumns( 'members', 'moremember', 'issues-table', 'json' ) %]
49 $(document).ready(function() {
50 $('#finesholdsissues').tabs({
51 // Correct table sizing for tables hidden in tabs
52 // http://www.datatables.net/examples/api/tabs_and_scrolling.html
53 "show": function(event, ui) {
54 var oTable = $('div.dataTables_wrapper>table', ui.panel).dataTable();
55 if ( oTable.length > 0 ) {
56 oTable.fnAdjustColumnSizing();
59 "activate": function( event, ui ) {
60 $('#'+ui.newTab.context.id).click();
63 $("#holdst").dataTable($.extend(true, {}, dataTablesDefaults, {
66 { "aTargets": [ -1,-2 ], "bSortable": false, "bSearchable": false }
69 { "sType": "title-string" },{ "sType": "anti-the" },null,null,null,null,null,null
74 // new YAHOO.widget.Button("delpicture"); // FIXME: formatting mismatch between YUI and normal button
75 $('#delpicture').click(function(){
76 return confirm(_("Are you sure you want to delete this patron image? This cannot be undone."));
78 $('#manage-patron-image').find("input[value*=Upload]").click(function(){
79 if($("#uploadfile").val() == ""){
80 alert(_("Please choose a file to upload"));
83 return confirm(_("Are you sure you want to replace the current patron image? This cannot be undone."));
86 $("#suspend_until").datepicker({ minDate: 1 }); // require that hold suspended until date is after today
87 $("#newduedate").datetimepicker({
88 minDate: 1, // require that renewal date is after today
93 function uncheck_sibling(me){
94 nodename=me.getAttribute("name");
95 if (nodename =="barcodes[]"){
96 var Node=me.parentNode.previousSibling;
97 while (Node.nodeName!="TD"){Node=Node.previousSibling}
98 var Nodes=Node.childNodes;
99 for (var i=0;i < Nodes.length;i++){
100 if (Nodes[i].nodeName=="INPUT" && Nodes[i].getAttribute("type")=="checkbox"){
101 Nodes[i].checked=false;
106 var Node=me.parentNode.nextSibling;
107 while (Node.nodeName!="TD"){Node=Node.nextSibling}
108 var Nodes=Node.childNodes;
109 for (var i=0;i<Nodes.length;i++){
110 if (Nodes[i].nodeName=="INPUT" && Nodes[i].getAttribute("type")=="checkbox"){
111 Nodes[i].checked=false;
116 function validate1(date) {
117 var today = new Date();
118 if ( date < today ) {
128 <body id="pat_moremember" class="pat">
129 [% INCLUDE 'header.inc' %]
130 [% INCLUDE 'patron-search.inc' %]
132 <div id="breadcrumbs">
133 <a href="/cgi-bin/koha/mainpage.pl">Home</a>
134 › <a href="/cgi-bin/koha/members/members-home.pl">Patrons</a>
135 › [% IF ( unknowuser ) %]Patron does not exist[% ELSE %]Patron details for [% INCLUDE 'patron-title.inc' %][% END %]
138 <div id="doc3" class="yui-t1">
143 [% INCLUDE 'members-toolbar.inc' %]
146 <div class="dialog alert">
147 [% IF ( error == 'CANT_DELETE_STAFF' ) %]
148 <h3>Unable to delete staff user</h3>
149 <p>Insufficient privileges.</p>
151 [% IF ( error == 'CANT_DELETE_YOURSELF' ) %]
152 <h3>Not allowed to delete own account</h3>
153 <p>Deleting your own account would lock you out of Koha.</p>
155 [% IF ( error == 'CANT_DELETE_OTHERLIBRARY' ) %]
156 <h3>Unable to delete patrons from other libraries with current settings</h3>
157 <p>Insufficient privileges.</p>
159 [% IF ( error == 'CANT_DELETE' ) %]
160 <h3>Unable to delete patron</h3>
161 <p>Insufficient privileges.</p>
167 [% IF ( unknowuser ) %]
168 <div class="dialog message">This patron does not exist.</div>
170 [% IF ( was_renewed ) %]<div class="dialog message">Patron's account has been renewed until [% dateexpiry | $KohaDates %]</div>[% END %]
173 <div id="circmessages" class="circmessage attention">
175 [% IF ( userdebarred ) %]
176 <li class="blocker">Patron's account is restricted
177 [% IF ( userdebarreddate ) %]
178 until [% userdebarreddate %]
181 [% IF ( debarredcomment ) %]
182 with the explanation: <i>[% debarredcomment | html_line_break %]</i>
184 <a href="#reldebarments" onclick="$('#debarments-tab-link').click()">View restrictions</a>
187 [% IF ( gonenoaddress ) %]<li class="blocker">Patron's address is in doubt.</li>[% END %]
188 [% IF ( lost ) %]<li class="blocker">Patron's card has been reported lost.</li>[% END %]
193 <h3>[% UNLESS ( I ) %]
194 [% title %] [% firstname %] [% END %] [% surname %] ([% cardnumber %])</h3>
195 <div class="yui-u first">
196 <div id="patron-information" style="padding : .5em;">
198 [% UNLESS ( I ) %][% IF ( othernames ) %]“[% othernames %]”[% END %]
200 <div class = "address">
201 [% IF Koha.Preference( 'AddressFormat' ) %]
202 [% INCLUDE "member-display-address-style-${ Koha.Preference( 'AddressFormat' ) }.inc" %]
204 [% INCLUDE 'member-display-address-style-us.inc' %]
211 [% IF ( phonepro ) %]<li><span class="label">Organization phone: </span>[% phonepro %]</li>[% END %]
212 [% IF ( emailpro ) %]<li><span class="label">Organization email: </span>[% emailpro %]</li>[% END %]
214 [% IF ( phone ) %]<li><span class="label">Primary phone: </span>[% phone %]</li>[% END %]
215 [% IF ( phonepro ) %]<li><span class="label">Secondary phone: </span>[% phonepro %]</li>[% END %]
216 [% IF ( mobile ) %]<li><span class="label">Other phone: </span>[% mobile %]</li>[% END %]
220 [% IF ( phone ) %]<li><span class="label">Primary phone: </span>[% phone %]</li>[% END %]
221 [% IF ( mobile ) %]<li><span class="label">Other phone: </span>[% mobile %]</li>[% END %]
223 [% IF ( fax ) %]<li><span class="label">Fax: </span>[% fax %]</li>[% END %]
225 [% IF ( email ) %]<li><span class="label">Primary email:</span><a href="mailto:[% email %]">[% email %]</a></li>[% END %]
226 [% IF ( emailpro ) %]<li><span class="label">Secondary email: </span><a href="mailto:[% emailpro %]">[% emailpro %]</a></li>[% END %]
228 [% IF ( initials ) %]<li><span class="label">Initials: </span>[% initials %]</li>[% END %]
229 [% IF ( dateofbirth ) %]<li><span class="label">Date of birth:</span>[% dateofbirth | $KohaDates %]</li>[% END %]
230 [% IF ( sex ) %]<li><span class="label">Gender:</span>
231 [% IF ( sex == 'F' ) %]Female[% ELSIF ( sex == 'M' ) %]Male[% ELSE %][% sex %][% END %]
232 </li>[% END %][% END %]
233 [% IF ( isguarantee ) %]
234 [% IF ( guaranteeloop ) %]
235 <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>
238 [% IF ( guarantorborrowernumber ) %]
239 <li><span class="label">Guarantor:</span><a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% guarantorborrowernumber %]">[% guarantorsurname %][%IF ( guarantorfirstname ) %], [% guarantorfirstname %] [% END %]</a></li>
245 [% IF ( guarantorborrowernumber ) %]
246 <a href="memberentry.pl?op=modify&borrowernumber=[% borrowernumber %]&step=1&guarantorid=[% guarantorborrowernumber %]">Edit</a>
248 <a href="memberentry.pl?op=modify&borrowernumber=[% borrowernumber %]&step=1">Edit</a>
253 <!-- Begin Upload Patron Image Section -->
255 <div id="manage-patron-image">
256 [% IF ( patronimages ) %]
257 [% IF ( CAN_user_tools_batch_upload_patron_images ) %]
258 <form method="post" action="/cgi-bin/koha/tools/picture-upload.pl" enctype="multipart/form-data">
259 <fieldset class="brief">
261 <legend>Manage Patron Image</legend>
262 <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.
264 <legend>Upload Patron Image</legend>
265 <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.
267 <br />Only PNG, GIF, JPEG, XPM formats are supported.
269 <input type="hidden" id="image" name="filetype" value="image" />
270 <input type="hidden" id="cardnumber" name="cardnumber" value="[% cardnumber %]" />
271 <input type="hidden" name="borrowernumber" value="[% borrowernumber %]" />
274 <label for="uploadfile">Select the file to upload: </label><input type="file" id="uploadfile" name="uploadfile" />
277 <fieldset class="action">
278 <input type="submit" value="Upload" class="submit" />
279 <input name="op" type="hidden" value="Upload" />
280 [% IF ( picture ) %]<a id="delpicture" href="/cgi-bin/koha/tools/picture-upload.pl?op=Delete&borrowernumber=[% borrowernumber %]" class="delete">Delete</a>[% END %]
288 <!-- End Upload Patron Image Section -->
290 [% IF ( ExtendedPatronAttributes ) %]
291 [% UNLESS ( no_patron_attribute_types ) %]
292 <div id="patron-extended-attributes" style="padding-top: 1em;">
293 <h3>Additional attributes and identifiers</h3>
294 [% FOREACH attribute IN attributes_loop %]
295 [% IF attribute.class %]
296 <div id="aai_[% attribute.class %]" class="rows">
298 <div id="aai" class="rows">
300 <h4>[% attribute.lib %]</h4>
302 [% FOREACH item IN attribute.items %]
304 <span class="label">[% item.description %]: </span>
305 [% IF ( item.value_description ) %]
306 [% item.value_description %]
308 [% item.value| html_line_break %]
316 <div class="action"><a href="memberentry.pl?op=modify&borrowernumber=[% borrowernumber %]&step=4">Edit</a></div>
320 [% IF ( EnhancedMessagingPreferences ) %]
321 <div id="patron-messaging-prefs" style="padding-top: 1em;">
322 <h3>Patron messaging preferences</h3>
323 [% INCLUDE 'messaging-preference-form.inc' %]
324 [% IF ( SMSSendDriver ) %]
325 <div class="rows"> <ol><li><span class="label">SMS number:</span>[% SMSnumber %]
329 <div class="action"><a href="memberentry.pl?op=modify&borrowernumber=[% borrowernumber %]&step=5">Edit</a></div>
334 <div id="patron-library-details">
338 <li><span class="label">Card number: </span>[% cardnumber %]</li>
339 <li><span class="label">Borrowernumber: </span> [% borrowernumber %]</li>
340 <li><span class="label">Category: </span>[% description %] ([% categorycode %])</li>
341 <li><span class="label">Registration date: </span>[% dateenrolled | $KohaDates %]</li>
343 <li><span class="label">Expiration date: </span>
344 [% IF ( was_renewed ) %]
345 <strong class="reregistrinfo">[% dateexpiry | $KohaDates %]</strong>
347 [% dateexpiry | $KohaDates %]
351 <li><span class="label">Library: </span>[% branchname %]</li>
353 [% IF ( OPACPrivacy ) %]<li><span class="label">Privacy Pref:</span>
354 [% IF ( privacy0 ) %]Forever[% END %]
355 [% IF ( privacy1 ) %]Default[% END %]
356 [% IF ( privacy2 ) %]Never[% END %]
360 <span class="label">Show checkouts to guarantor</span>
361 [% IF privacy_guarantor_checkouts %]
368 [% IF ( sort1 ) %]<li><span class="label">Sort field 1:</span>[% lib1 %]</li>[% END %]
369 [% IF ( sort2 ) %]<li><span class="label">Sort field 2:</span>[% lib2 %]</li>[% END %]
370 <li><span class="label">Username: </span>[% userid %]</li>
371 <li><span class="label">Password: </span>
372 [% IF ( password ) %]
375 <span class="problem"><a href="/cgi-bin/koha/members/member-password.pl?member=[% borrowernumber %]">Undefined</a></span>
378 [% IF ( borrowernotes ) %]<li><span class="label">Circulation note: </span>[% borrowernotes %]</li>[% END %]
379 [% IF ( opacnote ) %]<li><span class="label">OPAC note:</span>[% opacnote %]</li>[% END %]
380 [% IF Koha.Preference( 'NorwegianPatronDBEnable' ) == 1 %]
381 [% IF ( sync == 1 ) %]
382 <li><span class="label">Activate sync: </span>Yes</li>
383 [% IF ( syncstatus ) %]<li><span class="label">Sync status: </span>[% syncstatus %]</li>[% END %]
384 [% IF ( lastsync ) %]<li><span class="label">Last sync: </span>[% lastsync | $KohaDates %]</li>[% END %]
386 <li><span class="label">Activate sync: </span>No</li>
392 <div class="action"><a href="memberentry.pl?op=modify&borrowernumber=[% borrowernumber %]&step=3">Edit</a></div>
395 <div id="patron-alternate-address" style="padding-top: 1em;">
396 <h3>Alternate address</h3>
397 <div class="rows"> <ol><li><span class="label">Address: </span>[% B_address %]</li>
398 <li><span class="label">Address 2: </span>[% B_address2 %]</li>
399 <li><span class="label">City: </span>[% B_city %]</li>
400 [% IF ( B_state ) %]<li><span class="label">State: </span>[% B_state %]</li>[% END %]
401 <li><span class="label">ZIP/Postal code: </span>[% B_zipcode %]</li>
402 [% IF ( B_country ) %]<li><span class="label">Country: </span>[% B_country %]</li>[% END %]
403 [% IF ( B_phone ) %]<li><span class="label">Phone: </span>[% B_phone %]</li>[% END %]
404 [% IF ( B_email ) %]<li><span class="label">Email: </span><a href="mailto:[% B_email %]">[% B_email %]</a></li>[% END %]
405 [% IF ( contactnote ) %]<li><span class="label">Contact note: </span> [% contactnote %]</li>[% END %]
409 <div class="action"><a href="memberentry.pl?op=modify&borrowernumber=[% borrowernumber %]&step=6">Edit</a></div>
412 <div id="patron-alternative-contact" style="padding-top: 1em;">
413 <h3>Alternative contact</h3>
414 <div class="rows"> <ol><li><span class="label">Surname: </span>[% altcontactsurname %]</li>
415 <li><span class="label">First name: </span>[% altcontactfirstname %]</li>
416 <li><span class="label">Address: </span>[% altcontactaddress1 %]</li>
417 <li><span class="label">Address 2: </span>[% altcontactaddress2 %]</li>
418 <li><span class="label">City: </span>[% altcontactaddress3 %]</li>
419 [% IF ( altcontactstate ) %]<li><span class="label">State: </span>[% altcontactstate %]</li>[% END %]
420 <li><span class="label">ZIP/Postal code: </span>[% altcontactzipcode %]</li>
421 [% IF ( altcontactcountry ) %]<li><span class="label">Country: </span>[% altcontactcountry %]</li>[% END %]
422 [% IF ( altcontactphone ) %]<li><span class="label">Phone: </span>[% altcontactphone %]</li>[% END %]
425 <div class="action"><a href="memberentry.pl?op=modify&borrowernumber=[% borrowernumber %]&step=2">Edit</a></div>
430 <div id="finesholdsissues" class="toptabs">
432 <li><a href="#checkouts">[% issuecount %] Checkout(s)</a></li>
433 [% IF relatives_issues_count %]
434 <li><a href="#relatives-issues" id="relatives-issues-tab">Relatives' checkouts</a></li>
436 <li><a href="#finesandcharges">Fines & Charges</a></li>
438 [% IF ( holds_count ) %]
439 <a href="#reserves" id="holds-tab">[% holds_count %] Hold(s)</a>
441 <a href="#reserves" id="holds-tab">0 Holds</a>
444 <li><a id="debarments-tab-link" href="#reldebarments">[% debarments.size %] Restrictions</a></li>
447 [% INCLUDE "checkouts-table.inc" %]
449 [% IF ( relatives_issues_count ) %]
450 <div id="relatives-issues">
451 <table id="relatives-issues-table" style="width: 100% !Important;">
454 <th scope="col">Due date hidden not formatted</th>
455 <th scope="col">Due date</th>
456 <th scope="col">Title</th>
457 <th scope="col">Item type</th>
458 <th scope="col">Location</th>
459 <th scope="col">Checked out on</th>
460 <th scope="col">Checked out from</th>
461 <th scope="col">Call no</th>
462 <th scope="col">Charge</th>
463 <th scope="col">Fine</th>
464 <th scope="col">Price</th>
465 <th scope="col">Patron</th>
472 <div id="finesandcharges">
473 [% IF ( totaldue_raw ) %]
474 <p>Total due: [% totaldue %]</p>
476 <p>No outstanding charges</p>
480 [% INCLUDE borrower_debarments.inc %]
483 [% IF ( holds_count ) %]
484 <form action="/cgi-bin/koha/reserve/modrequest.pl" method="post">
485 <input type="hidden" name="from" value="circ" />
486 <table id="holds-table" style="width: 100% !Important;">
501 <fieldset class="action">
502 <input type="submit" class="cancel" name="submit" value="Cancel marked holds" />
506 [% IF SuspendHoldsIntranet %]
507 <fieldset class="action">
508 <form action="/cgi-bin/koha/reserve/modrequest_suspendall.pl" method="post">
509 <input type="hidden" name="from" value="borrower" />
510 <input type="hidden" name="borrowernumber" value="[% borrowernumber %]" />
511 <input type="submit" value="Suspend all holds" />
513 [% IF AutoResumeSuspendedHolds %]
514 <label for="suspend_until">until</label>
515 <input type="text" size="10" id="suspend_until" name="suspend_until"/>
516 <span class="hint">Specify date on which to resume [% INCLUDE 'date-format.inc' %]: </span>
521 <fieldset class="action">
522 <form action="/cgi-bin/koha/reserve/modrequest_suspendall.pl" method="post">
523 <input type="hidden" name="from" value="borrower" />
524 <input type="hidden" name="borrowernumber" value="[% borrowernumber %]" />
525 <input type="hidden" name="suspend" value="0" />
526 <input type="submit" value="Resume all suspended holds" />
529 [% END # IF SuspendHoldsIntranet %]
531 [% ELSE %]<p>Patron has nothing on hold.</p>[% END %]
535 [% END %] <!-- unknowuser -->
541 [% INCLUDE 'circ-menu.inc' %]
544 [% INCLUDE 'intranet-bottom.inc' %]