4 [% SET userupdateview = 1 %]
6 [% INCLUDE 'doc-head-open.inc' %]
7 <title>[% IF ( LibraryNameTitle ) %][% LibraryNameTitle %][% ELSE %]Koha online[% END %] catalog › [% IF action == 'edit' %]Update your personal details[% ELSE %]Register a new account[% END %]</title>
8 [% INCLUDE 'doc-head-close.inc' %]
9 [% BLOCK cssinclude %][% END %]
12 [% IF action == 'edit' %]
13 [% INCLUDE 'bodytag.inc' bodyid='opac-patron-update' %]
15 <body id="opac-patron-registration" class="opac">
17 [% INCLUDE 'masthead.inc' %]
20 <ul class="breadcrumb">
21 <li><a href="/cgi-bin/koha/opac-main.pl">Home</a> <span class="divider">›</span></li>
22 [% IF action == 'edit' %]
23 <li><a href="/cgi-bin/koha/opac-user.pl">[% borrower.firstname %] [% borrower.surname %]</a> <span class="divider">›</span></li>
24 <li><a href="#">Your personal details</a></li>
26 <li><a href="#">Register a new account</a></li>
30 <div class="container-fluid">
31 <div class="row-fluid">
34 [% INCLUDE 'navigation.inc' IsPatronPage=1 %]
38 [% IF action == 'edit' %]
39 <div id="update-account">
41 <div id="add-account">
44 [% IF action == 'edit' %]
45 [% UNLESS OPACPatronDetails %]
46 <div class="alert alert-info">To make changes to your record please contact the library.</div>
49 <div class="alert alert-error">No changes were made.</div>
53 [% IF empty_mandatory_fields %]
54 <div class="alert">You have not filled out all required fields. Please fill in all missing fields and resubmit.</div>
57 [% IF invalid_form_fields %]
58 <div class="alert alert-error"><strong>The following fields contain invalid information:</strong>
60 [% FOREACH field IN invalid_form_fields %]
61 [% IF field == "email" %]<li>Contact information: <a href="#borrower_email">primary email address</a></li>[% END %]
62 [% IF field == "emailpro" %]<li>Contact information: <a href="#borrower_emailpro">secondary email address</a></li>[% END %]
63 [% IF field == "B_email" %]<li>Alternate address information: <a href="#borrower_B_email">email address</a></li>[% END %]
64 [% IF field == "password_match" %]<li>Passwords do not match! <a href="#password">password</a></li>[% END %]
65 [% IF field == "password_invalid" %]<li>Password does not meet minimum requirements! <a href="#password">password</a></li>[% END %]
66 [% IF field == "password_spaces" %]<li>Password contains leading and/or trailing spaces! <a href="#password">password</a></li>[% END %]
69 Please correct the errors and resubmit.
73 [% IF cardnumber_wrong_length || cardnumber_already_exists %]
74 <div class="alert alert-error">
75 [% IF cardnumber_wrong_length %]
76 <a href="#borrower_cardnumber"><strong>The entered card number is the wrong length.</strong></a>
77 [% ELSIF cardnumber_already_exists %]
78 <a href="#borrower_cardnumber"><strong>The entered card number is already in use.</strong></a>
80 Please correct this and resubmit.
84 [% IF failed_captcha %]
85 <div class="alert">You typed in the wrong characters in the box before submitting. Please try again.</div>
88 [% IF borrower.guarantorid && !Koha.Preference('OPACPrivacy') && Koha.Preference('AllowPatronToSetCheckoutsVisibilityForGuarantor') %]
89 <fieldset class="rows" id="memberentry_privacy">
90 <legend id="privacy_legend">Privacy</legend>
93 <label>Allow your guarantor to view your current checkouts?</label>
94 <select id="privacy_guarantor_checkouts">
95 <option value="0">No</option>
96 [% IF borrower.privacy_guarantor_checkouts %]
97 <option value="1" selected="selected">Yes</option>
99 <option value="1">Yes</option>
103 <a id="update_privacy_guarantor_checkouts" href="#" class="btn">Update</a>
104 <span id="update_privacy_guarantor_checkouts_message" class="alert" style="display:none"></span>
107 Your guarantor is <i>[% guarantor.firstname %] [% guarantor.surname %]</i>
114 <form method="post" action="/cgi-bin/koha/opac-memberentry.pl" id="memberentry-form">
116 [% UNLESS hidden.defined('branchcode') %]
117 <fieldset class="rows" id="memberentry_library">
119 <legend id="library_legend">Library</legend>
121 [% UNLESS hidden.defined('cardnumber') || ( !borrower && Koha.Preference('autoMemberNum') ) %]
123 [% IF mandatory.defined('cardnumber') %]
124 <label for="borrower_cardnumber" class="required">
126 <label for="borrower_cardnumber">
131 [% borrower.cardnumber %]
133 <input type="text" id="borrower_cardnumber" name="borrower_cardnumber" value="[% borrower.cardnumber %]" />
134 [% IF mandatory.defined('cardnumber') %]<span class="required">Required</span>[% END %]
139 [% UNLESS hidden.defined('dateexpiry') %]
141 <label>Expiration date:</label>
142 [% borrower.dateexpiry | $KohaDates %]
146 [% UNLESS hidden.defined('branchcode') %]
148 [% IF mandatory.defined('branchcode') %]
149 <label for="borrower_branchcode" class="required">
151 <label for="borrower_branchcode">
153 Home library:</label>
155 <select id="borrower_branchcode" name="borrower_branchcode">
156 [% FOREACH b IN branches %]
157 [% IF b.value == borrower.branchcode %]
158 <option value="[% b.value %]" selected="selected">[% b.branchname %]</option>
160 <option value="[% b.value %]">[% b.branchname %]</option>
167 [% UNLESS hidden.defined('categorycode') %]
169 <label for="borrower_categorycode">
173 [% Categories.GetName( borrower.categorycode ) %]
175 <select id="borrower_categorycode" name="borrower_categorycode">
176 [% FOREACH c IN Categories.all() %]
177 [% IF c.categorycode == Koha.Preference('PatronSelfRegistrationDefaultCategory') %]
178 <option value="[% c.categorycode %]" selected="selected">[% c.description %]</option>
180 <option value="[% c.categorycode %]">[% c.description %]</option>
189 [% END # / defined 'branchcode' %]
192 hidden.defined('title') && hidden.defined('surname') && hidden.defined('firstname') &&
193 hidden.defined('dateofbirth') && hidden.defined('initials') && hidden.defined('othernames') &&
194 hidden.defined('sex')
196 <div class="row-fluid">
197 [% IF ( display_patron_image ) %]
202 <fieldset class="rows" id="memberentry_identity">
203 <legend id="identity_legend">Identity</legend>
206 [% UNLESS hidden.defined('title') || !Koha.Preference('BorrowersTitles') %]
208 [% IF mandatory.defined('title') %]
209 <label for="borrower_title" class="required">
211 <label for="borrower_title">
215 <select id="borrower_title" name="borrower_title">
216 [% FOREACH mt IN Koha.Preference('BorrowersTitles').split('\|') %]
217 [% IF mt == borrower.title %]
218 <option value="[% mt %]" selected="selected">[% mt %]</option>
220 <option value="[% mt %]">[% mt %]</option>
227 [% UNLESS hidden.defined('surname') %]
229 [% IF mandatory.defined('surname') %]
230 <label for="borrower_surname" class="required">
232 <label for="borrower_surname">
236 <input type="text" id="borrower_surname" name="borrower_surname" value="[% borrower.surname %]" />
237 [% IF mandatory.defined('surname') %]<span class="required">Required</span>[% END %]
241 [% UNLESS hidden.defined('firstname') %]
243 [% IF mandatory.defined('firstname') %]
244 <label for="borrower_firstname" class="required">
246 <label for="borrower_firstname">
250 <input type="text" id="borrower_firstname" name="borrower_firstname" value="[% borrower.firstname %]" />
251 [% IF mandatory.defined('firstname') %]<span class="required">Required</span>[% END %]
255 [% UNLESS hidden.defined('dateofbirth') %]
257 [% IF mandatory.defined('dateofbirth') %]
258 <label for="borrower_dateofbirth" class="required">
260 <label for="borrower_dateofbirth">
262 Date of birth:</label>
264 <input type="text" id="borrower_dateofbirth" name="borrower_dateofbirth" value="[% borrower.dateofbirth | $KohaDates %]" size="10" />
266 [% UNLESS action == 'edit' && !OPACPatronDetails %]
267 [% UNLESS ( mandatory.defined('dateofbirth') ) %]
268 <a href="#" style="font-size:85%;text-decoration:none;" onclick="document.getElementById('borrower_dateofbirth').value='';return false;">Clear date</a>
272 [% IF mandatory.defined('dateofbirth') %]<span class="required">Required</span>[% END %]
276 [% UNLESS hidden.defined('initials') %]
278 [% IF mandatory.defined('initials') %]
279 <label for="borrower_initials" class="required">
281 <label for="borrower_initials">
285 <input type="text" id="borrower_initials" name="borrower_initials" value="[% borrower.initials %]" />
286 [% IF mandatory.defined('initials') %]<span class="required">Required</span>[% END %]
290 [% UNLESS hidden.defined('othernames') %]
292 [% IF mandatory.defined('othernames') %]
293 <label for="borrower_othernames" class="required">
295 <label for="borrower_othernames">
299 <input type="text" id="borrower_othernames" name="borrower_othernames" value="[% borrower.othernames %]" />
300 [% IF mandatory.defined('othernames') %]<span class="required">Required</span>[% END %]
304 [% UNLESS hidden.defined('sex') %]
306 <label for="sex-female" class="radio inline">Female:</label>
307 [% IF borrower.sex == 'F' %]
308 <input type="radio" name="borrower_sex" id="sex-female" value="F" checked="checked" />
310 <input type="radio" name="borrower_sex" id="sex-female" value="F" />
313 <label for="sex-male" class="radio inline">Male:</label>
314 [% IF borrower.sex == 'M' %]
315 <input type="radio" name="borrower_sex" id="sex-male" value="M" checked="checked" />
317 <input type="radio" name="borrower_sex" id="sex-male" value="M" />
320 <label for="sex-none" class="radio inline">None specified: </label>
321 [% IF borrower.sex == '' %]
322 <input type="radio" name="borrower_sex" id="sex-none" value="" checked="checked" />
324 <input type="radio" name="borrower_sex" id="sex-none" value="" />
327 [% IF mandatory.defined('sex') %]<span class="required">Required</span>[% END %]
333 [% IF ( display_patron_image ) %]
335 <p class="patronimage">
336 <img src="/cgi-bin/koha/opac-patron-image.pl" alt="" />
341 [% END # /UNLESS fields hidden %]
344 hidden.defined('streetnumber') && hidden.defined('address') && hidden.defined('address2') &&
345 hidden.defined('city') && hidden.defined('state') && hidden.defined('zipcode') &&
346 hidden.defined('country')
348 <fieldset class="rows" id="memberentry_mainaddress">
349 <legend id="mainaddress_legend">Main address</legend>
352 [% UNLESS hidden.defined('streetnumber') %]
354 [% IF mandatory.defined('streetnumber') %]
355 <label for="borrower_streetnumber" class="required">
357 <label for="borrower_streetnumber">
359 Street number:</label>
361 <input type="text" id="borrower_streetnumber" name="borrower_streetnumber" value="[% borrower.streetnumber %]" />
362 [% IF mandatory.defined('streetnumber') %]<span class="required">Required</span>[% END %]
366 [% UNLESS hidden.defined('address') %]
368 [% IF mandatory.defined('address') %]
369 <label for="borrower_address" class="required">
371 <label for="borrower_address">
375 <input type="text" id="borrower_address" name="borrower_address" value="[% borrower.address %]" />
376 [% IF mandatory.defined('address') %]<span class="required">Required</span>[% END %]
380 [% UNLESS hidden.defined('address2') %]
382 [% IF mandatory.defined('address2') %]
383 <label for="borrower_address2" class="required">
385 <label for="borrower_address2">
389 <input type="text" id="borrower_address2" name="borrower_address2" value="[% borrower.address2 %]" />
390 [% IF mandatory.defined('address2') %]<span class="required">Required</span>[% END %]
394 [% UNLESS hidden.defined('city') %]
396 [% IF mandatory.defined('city') %]
397 <label for="borrower_city" class="required">
399 <label for="borrower_city">
403 <input type="text" id="borrower_city" name="borrower_city" value="[% borrower.city %]" />
404 [% IF mandatory.defined('city') %]<span class="required">Required</span>[% END %]
408 [% UNLESS hidden.defined('state') %]
410 [% IF mandatory.defined('state') %]
411 <label for="borrower_state" class="required">
413 <label for="borrower_state">
417 <input type="text" id="borrower_state" name="borrower_state" value="[% borrower.state %]" />
418 [% IF mandatory.defined('state') %]<span class="required">Required</span>[% END %]
422 [% UNLESS hidden.defined('zipcode') %]
424 [% IF mandatory.defined('zipcode') %]
425 <label for="borrower_zipcode" class="required">
427 <label for="borrower_zipcode">
429 ZIP/Postal code:</label>
431 <input type="text" id="borrower_zipcode" name="borrower_zipcode" value="[% borrower.zipcode %]" />
432 [% IF mandatory.defined('zipcode') %]<span class="required">Required</span>[% END %]
436 [% UNLESS hidden.defined('country') %]
438 [% IF mandatory.defined('country') %]
439 <label for="borrower_country" class="required">
441 <label for="borrower_country">
445 <input type="text" id="borrower_country" name="borrower_country" value="[% borrower.country %]" />
446 [% IF mandatory.defined('country') %]<span class="required">Required</span>[% END %]
455 hidden.defined('phone') && hidden.defined('phonepro') && hidden.defined('mobile') &&
456 hidden.defined('email') && hidden.defined('emailpro') && hidden.defined('fax')
458 <fieldset class="rows" id="memberentry_contact">
459 <legend id="contact_legend">Contact information</legend>
462 [% UNLESS hidden.defined('phone') %]
464 [% IF mandatory.defined('phone') %]
465 <label for="borrower_phone" class="required">
467 <label for="borrower_phone">
469 Primary phone:</label>
471 <input type="text" id="borrower_phone" name="borrower_phone" value="[% borrower.phone %]" />
472 [% IF mandatory.defined('phone') %]<span class="required">Required</span>[% END %]
476 [% UNLESS hidden.defined('phonepro') %]
478 [% IF mandatory.defined('phonepro') %]
479 <label for="borrower_phonepro" class="required">
481 <label for="borrower_phonepro">
483 Secondary phone:</label>
485 <input type="text" id="borrower_phonepro" name="borrower_phonepro" value="[% borrower.phonepro %]" />
486 [% IF mandatory.defined('phonepro') %]<span class="required">Required</span>[% END %]
490 [% UNLESS hidden.defined('mobile') %]
492 [% IF mandatory.defined('mobile') %]
493 <label for="borrower_mobile" class="required">
495 <label for="borrower_mobile">
499 <input type="text" id="borrower_mobile" name="borrower_mobile" value="[% borrower.mobile %]" />
500 [% IF mandatory.defined('mobile') %]<span class="required">Required</span>[% END %]
504 [% UNLESS hidden.defined('email') %]
506 [% IF mandatory.defined('email') %]
507 <label for="borrower_email" class="required">
509 <label for="borrower_email">
511 Primary email:</label>
513 <input type="text" id="borrower_email" name="borrower_email" value="[% borrower.email %]" />
514 [% IF mandatory.defined('email') %]<span class="required">Required</span>[% END %]
518 [% UNLESS hidden.defined('emailpro') %]
520 [% IF mandatory.defined('emailpro') %]
521 <label for="borrower_emailpro" class="required">
523 <label for="borrower_emailpro">
525 Secondary email:</label>
527 <input type="text" id="borrower_emailpro" name="borrower_emailpro" value="[% borrower.emailpro %]" />
528 [% IF mandatory.defined('emailpro') %]<span class="required">Required</span>[% END %]
532 [% UNLESS hidden.defined('fax') %]
534 [% IF mandatory.defined('fax') %]
535 <label for="borrower_fax" class="required">
537 <label for="borrower_fax">
541 <input type="text" id="borrower_fax" name="borrower_fax" value="[% borrower.fax %]" />
542 [% IF mandatory.defined('fax') %]<span class="required">Required</span>[% END %]
550 hidden.defined('B_address') && hidden.defined('B_address2') && hidden.defined('B_city') &&
551 hidden.defined('B_state') && hidden.defined('B_zipcode') && hidden.defined('B_country') &&
552 hidden.defined('B_phone') && hidden.defined('B_email') && hidden.defined('contactnote')
554 <fieldset class="rows" id="memberentry_alternateaddress">
555 <legend id="alternateaddress_legend">Alternate address</legend>
558 [% UNLESS hidden.defined('B_address') %]
560 [% IF mandatory.defined('B_address') %]
561 <label for="borrower_B_address" class="required">
563 <label for="borrower_B_address">
567 <input type="text" id="borrower_B_address" name="borrower_B_address" value="[% borrower.B_address %]" />
568 [% IF mandatory.defined('B_address') %]<span class="required">Required</span>[% END %]
572 [% UNLESS hidden.defined('B_address2') %]
574 [% IF mandatory.defined('B_address2') %]
575 <label for="borrower_B_address2" class="required">
577 <label for="borrower_B_address2">
581 <input type="text" id="borrower_B_address2" name="borrower_B_address2" value="[% borrower.B_address2 %]" />
582 [% IF mandatory.defined('B_address2') %]<span class="required">Required</span>[% END %]
586 [% UNLESS hidden.defined('B_city') %]
588 [% IF mandatory.defined('B_city') %]
589 <label for="borrower_B_city" class="required">
591 <label for="borrower_B_city">
595 <input type="text" id="borrower_B_city" name="borrower_B_city" value="[% borrower.B_city %]" />
596 [% IF mandatory.defined('B_city') %]<span class="required">Required</span>[% END %]
600 [% UNLESS hidden.defined('B_state') %]
602 [% IF mandatory.defined('B_state') %]
603 <label for="borrower_B_state" class="required">
605 <label for="borrower_B_state">
609 <input type="text" id="borrower_B_state" name="borrower_B_state" value="[% borrower.B_state %]" />
610 [% IF mandatory.defined('B_state') %]<span class="required">Required</span>[% END %]
614 [% UNLESS hidden.defined('B_zipcode') %]
616 [% IF mandatory.defined('B_zipcode') %]
617 <label for="borrower_B_zipcode" class="required">
619 <label for="borrower_B_zipcode">
621 ZIP/Postal code:</label>
623 <input type="text" id="borrower_B_zipcode" name="borrower_B_zipcode" value="[% borrower.B_zipcode %]" />
624 [% IF mandatory.defined('B_zipcode') %]<span class="required">Required</span>[% END %]
628 [% UNLESS hidden.defined('B_country') %]
630 [% IF mandatory.defined('B_country') %]
631 <label for="borrower_B_country" class="required">
633 <label for="borrower_B_country">
637 <input type="text" id="borrower_B_country" name="borrower_B_country" value="[% borrower.B_country %]" />
638 [% IF mandatory.defined('B_country') %]<span class="required">Required</span>[% END %]
642 [% UNLESS hidden.defined('B_phone') %]
644 [% IF mandatory.defined('B_phone') %]
645 <label for="borrower_B_phone" class="required">
647 <label for="borrower_B_phone">
651 <input type="text" id="borrower_B_phone" name="borrower_B_phone" value="[% borrower.B_phone %]" />
652 [% IF mandatory.defined('B_phone') %]<span class="required">Required</span>[% END %]
656 [% UNLESS hidden.defined('B_email') %]
658 [% IF mandatory.defined('B_email') %]
659 <label for="borrower_B_email" class="required">
661 <label for="borrower_B_email">
665 <input type="text" id="borrower_B_email" name="borrower_B_email" value="[% borrower.B_email %]" />
666 [% IF mandatory.defined('B_email') %]<span class="required">Required</span>[% END %]
670 [% UNLESS hidden.defined('contactnote') %]
672 [% IF mandatory.defined('contactnote') %]
673 <label for="borrower_contactnote" class="required">
675 <label for="borrower_contactnote">
677 Contact note:</label>
679 <textarea id="borrower_contactnote" name="borrower_contactnote" cols="30" rows="2">[% borrower.contactnote %]</textarea>
680 [% IF mandatory.defined('contactnote') %]<span class="required">Required</span>[% END %]
689 hidden.defined('altcontactsurname') && hidden.defined('altcontactfirstname') && hidden.defined('altcontactaddress1') &&
690 hidden.defined('altcontactaddress2') && hidden.defined('altcontactaddress3') && hidden.defined('altcontactstate') &&
691 hidden.defined('altcontactzipcode') && hidden.defined('altcontactcountry') && hidden.defined('altcontactphone')
693 <fieldset class="rows" id="memberentry_alternatecontact">
694 <legend id="alternatecontact_legend">Alternate contact</legend>
697 [% UNLESS hidden.defined('altcontactsurname') %]
699 [% IF mandatory.defined('altcontactsurname') %]
700 <label for="borrower_altcontactsurname" class="required">
702 <label for="borrower_altcontactsurname">
706 <input type="text" id="borrower_altcontactsurname" name="borrower_altcontactsurname" value="[% borrower.altcontactsurname %]" />
707 [% IF mandatory.defined('altcontactsurname') %]<span class="required">Required</span>[% END %]
711 [% UNLESS hidden.defined('altcontactfirstname') %]
713 [% IF mandatory.defined('altcontactfirstname') %]
714 <label for="borrower_altcontactfirstname" class="required">
716 <label for="borrower_altcontactfirstname">
720 <input type="text" id="borrower_altcontactfirstname" name="borrower_altcontactfirstname" value="[% borrower.altcontactfirstname %]" />
721 [% IF mandatory.defined('altcontactfirstname') %]<span class="required">Required</span>[% END %]
725 [% UNLESS hidden.defined('altcontactaddress1') %]
727 [% IF mandatory.defined('altcontactaddress1') %]
728 <label for="borrower_altcontactaddress1" class="required">
730 <label for="borrower_altcontactaddress1">
734 <input type="text" id="borrower_altcontactaddress1" name="borrower_altcontactaddress1" value="[% borrower.altcontactaddress1 %]" />
735 [% IF mandatory.defined('altcontactaddress1') %]<span class="required">Required</span>[% END %]
739 [% UNLESS hidden.defined('altcontactaddress2') %]
741 [% IF mandatory.defined('altcontactaddress2') %]
742 <label for="borrower_altcontactaddress2" class="required">
744 <label for="borrower_altcontactaddress2">
748 <input type="text" id="borrower_altcontactaddress2" name="borrower_altcontactaddress2" value="[% borrower.altcontactaddress2 %]" />
749 [% IF mandatory.defined('altcontactaddress2') %]<span class="required">Required</span>[% END %]
753 [% UNLESS hidden.defined('altcontactaddress3') %]
755 [% IF mandatory.defined('altcontactaddress3') %]
756 <label for="borrower_altcontactaddress3" class="required">
758 <label for="borrower_altcontactaddress3">
762 <input type="text" id="borrower_altcontactaddress3" name="borrower_altcontactaddress3" value="[% borrower.altcontactaddress3 %]" />
763 [% IF mandatory.defined('altcontactaddress3') %]<span class="required">Required</span>[% END %]
767 [% UNLESS hidden.defined('altcontactstate') %]
769 [% IF mandatory.defined('altcontactstate') %]
770 <label for="borrower_altcontactstate" class="required">
772 <label for="borrower_altcontactstate">
776 <input type="text" id="borrower_altcontactstate" name="borrower_altcontactstate" value="[% borrower.altcontactstate %]" />
777 [% IF mandatory.defined('altcontactstate') %]<span class="required">Required</span>[% END %]
781 [% UNLESS hidden.defined('altcontactzipcode') %]
783 [% IF mandatory.defined('altcontactzipcode') %]
784 <label for="borrower_altcontactzipcode" class="required">
786 <label for="borrower_altcontactzipcode">
788 ZIP/Postal code:</label>
790 <input type="text" id="borrower_altcontactzipcode" name="borrower_altcontactzipcode" value="[% borrower.altcontactzipcode %]" />
791 [% IF mandatory.defined('altcontactzipcode') %]<span class="required">Required</span>[% END %]
795 [% UNLESS hidden.defined('altcontactcountry') %]
797 [% IF mandatory.defined('altcontactcountry') %]
798 <label for="borrower_altcontactcountry" class="required">
800 <label for="borrower_altcontactcountry">
804 <input type="text" id="borrower_altcontactcountry" name="borrower_altcontactcountry" value="[% borrower.altcontactcountry %]" />
805 [% IF mandatory.defined('altcontactcountry') %]<span class="required">Required</span>[% END %]
809 [% UNLESS hidden.defined('altcontactphone') %]
811 [% IF mandatory.defined('altcontactphone') %]
812 <label for="borrower_altcontactphone" class="required">
814 <label for="borrower_altcontactphone">
818 <input type="text" id="borrower_altcontactphone" name="borrower_altcontactphone" value="[% borrower.altcontactphone %]" />
819 [% IF mandatory.defined('altcontactphone') %]<span class="required">Required</span>[% END %]
826 [% UNLESS action == 'edit' || hidden.defined('password') %]
827 <fieldset class="rows" id="memberentry_password">
828 <legend id="contact_legend">Password</legend>
829 [% IF Koha.Preference('minPasswordLength') || !mandatory.defined('password') %]
830 <div class="alert alert-info">
831 [% IF Koha.Preference('minPasswordLength') %]
832 <p>Your password must be at least [% Koha.Preference('minPasswordLength') %] characters long.</p>
834 [% UNLESS mandatory.defined('password') %]
835 If you do not enter a password a system generated password will be created.
840 [% IF mandatory.defined('password') %]
842 <li><label for="borrower_password" class="required">Password</label>
843 <input type="text" name="borrower_password" id="password" />
844 <span class="required">Required</span>
846 <li><label for="borrower_password2" class="required">Confirm password</label>
847 <input type="text" name="borrower_password2" id="password2" />
848 <span class="required">Required</span>
853 <li><label for="borrower_password">Password</label>
854 <input type="text" name="borrower_password" id="password" />
856 <li><label for="borrower_password2">Confirm password</label>
857 <input type="text" name="borrower_password2" id="password2" />
864 [% UNLESS action == 'edit' %]
865 <fieldset class="rows" id="memberentry_captcha">
869 <label for="captcha" class="required">Verification:</label>
871 <input type="text" name="captcha" id="captcha" />
872 <input type="hidden" name="captcha_digest" value="[% captcha_digest %]" />
874 <span class="hint">Please type the following characters into the preceding box: <strong>[% captcha %]</strong></span>
880 [% IF ( borrower.ExtendedPatronAttributes ) %]
881 <fieldset class="rows">
882 <legend>Additional information</legend>
884 [% FOREACH patron_attribute IN borrower.patron_attributes %]
886 <label>[% patron_attribute.description %]:</label>
887 [% IF ( patron_attribute.value_description ) %]
888 [% patron_attribute.value_description %]
890 [% patron_attribute.value |html_line_break %]
898 [% IF action == 'edit' %]
899 [% IF OPACPatronDetails %]
900 <fieldset class="action">
901 <input type="hidden" name="action" value="update" />
902 <input type="submit" class="btn" value="Submit update request" />
906 <fieldset class="action">
907 <input type="hidden" name="action" value="create" />
908 <input type="submit" class="btn" value="Submit" />
914 </div><!--/div id="update-account" -->
920 [% INCLUDE 'opac-bottom.inc' %]
921 [% BLOCK jsinclude %]
922 <script type="text/javascript" src="[% interface %]/[% theme %]/lib/jquery/plugins/jquery.validate.min.js"></script>
923 <script type="text/javascript">
925 $(document).ready(function() {
926 [% IF action == 'edit' && !OPACPatronDetails %]
927 $("#memberentry-form :input").attr('readonly', true);
928 $("#borrower_branchcode").attr('disabled',true);
929 $("#borrower_title").attr('disabled',true);
930 $('#memberentry-form :radio').attr('disabled',true);
931 $('span.required').remove();
932 $('label.required').removeClass('required');
934 $( "#borrower_dateofbirth" ).datepicker({ yearRange: "c-120:c" });
937 $("#memberentry-form").validate({
949 submitHandler: function(form) {
950 if (form.beenSubmitted) {
954 form.beenSubmitted = true;
958 errorPlacement: function(error, element) {
959 offset = element.offset();
960 error.insertAfter(element)
961 error.addClass('error'); // add a class to the wrapper
962 error.css('position', 'absolute');
963 error.css('left', offset.left + element.outerWidth() + 10);
964 error.css('top', offset.top);
965 error.css('width', 'auto');
969 [% IF borrower.guarantorid && !Koha.Preference('OPACPrivacy') && Koha.Preference('AllowPatronToSetCheckoutsVisibilityForGuarantor') %]
970 $('#update_privacy_guarantor_checkouts').click( function() {
971 $.post( "/cgi-bin/koha/svc/patron/show_checkouts_to_relatives", { privacy_guarantor_checkouts: $('#privacy_guarantor_checkouts').val() }, null, 'json')
972 .done(function( data ) {
974 if ( data.success ) {
975 message = _("Your setting has been updated!");
977 message = _("Unable to update your setting!");
980 $('#update_privacy_guarantor_checkouts_message').fadeIn("slow").text( message ).delay( 5000 ).fadeOut("slow");
987 [% INCLUDE 'calendar.inc' %]