1 [% INCLUDE 'doc-head-open.inc' %]
2 <title>Koha › Patrons [% IF ( searching ) %]› Search results[% END %]</title>
3 [% INCLUDE 'doc-head-close.inc' %]
5 <script type="text/javascript">
7 $(document).ready(function() {
8 $('#add_to_patron_list_submit').attr('disabled', 'disabled');
9 $('#new_patron_list').hide();
11 $('#add_to_patron_list').change(function() {
12 var value = $('#add_to_patron_list').val();
13 if ( value == 'new' ) {
14 $('#new_patron_list').val('')
15 $('#new_patron_list').show();
16 $('#new_patron_list').focus();
18 $('#new_patron_list').hide();
19 $('#add_to_patron_list_submit').removeAttr('disabled');
21 $('#new_patron_list').hide();
22 $('#add_to_patron_list_submit').attr('disabled', 'disabled');
27 $('#new_patron_list').on('input', function() {
28 if ( $('#new_patron_list').val() ) {
29 $('#add_to_patron_list_submit').removeAttr('disabled');
31 $('#add_to_patron_list_submit').attr('disabled', 'disabled');
36 function CheckForm() {
37 if ( $('#add_to_patron_list').val() == 'new' ) {
38 if ( $('#new_patron_list').val() ) {
40 $("#add_to_patron_list option").each(function() {
41 if ( $(this).text() == $('#new_patron_list').val() ) {
48 alert( _("You already have a list with that name!") );
52 alert( _("You must give your new patron list a name!") );
57 if ( $('#add_to_patron_list_which').val() == 'all' ) {
58 return confirm( _("Are you sure you want to add the entire set of patron results to this list ( including results on other pages )?") );
60 if ( $("#add-patrons-to-list-form input:checkbox:checked").length == 0 ) {
61 alert( _("You have not selected any patrons to add to a list!") );
72 <body id="pat_member" class="pat">
73 [% INCLUDE 'header.inc' %]
74 [% INCLUDE 'patron-search.inc' %]
76 <div id="breadcrumbs"><a href="/cgi-bin/koha/mainpage.pl">Home</a> › [% IF ( searching ) %]<a href="/cgi-bin/koha/members/members-home.pl">Patrons</a> › Search results[% ELSE %]Patrons[% END %]</div>
78 <div id="doc2" class="yui-t7">
86 <div class="dialog alert">
87 Added [% patrons_added_to_list.size %] patrons to <a href="/cgi-bin/koha/patron_lists/list.pl?patron_list_id=[% patron_list.patron_list_id %]">[% patron_list.name %]</a>.
91 [% INCLUDE 'patron-toolbar.inc' %]
93 [% IF ( no_add ) %]<div class="dialog alert"><h3>Cannot add patron</h3>
94 [% IF ( no_branches ) %]<p>There are <strong>no libraries defined</strong>. [% IF ( CAN_user_parameters ) %]Please <a href="/cgi-bin/koha/admin/branches.pl">add a library</a>.[% ELSE %]An administrator must define at least one library.[% END %]</p>[% END %]
95 [% IF ( no_categories ) %]<p>There are <strong>no patron categories defined</strong>. [% IF ( CAN_user_parameters ) %]Please <a href="/cgi-bin/koha/admin/categorie.pl">add a patron category</a>.[% ELSE %]An administrator must define at least one patron category.[% END %]</p>[% END %]</div>
100 [% FOREACH letter IN alphabet.split(' ') %]
101 <a href="/cgi-bin/koha/members/member.pl?quicksearch=1&surname=[% letter %]">[% letter %]</a>
105 [% IF ( CAN_user_borrowers && pending_borrower_modifications ) %]
106 <div class="pending-info" id="patron_updates_pending">
107 <a href="/cgi-bin/koha/members/members-update.pl">Patrons requesting modifications</a>:
108 <span class="holdcount"><a href="/cgi-bin/koha/members/members-update.pl">[% pending_borrower_modifications %]</a></span>
112 [% IF ( resultsloop ) %]
113 <form id="add-patrons-to-list-form" method="post" action="member.pl" onsubmit="return CheckForm()">
114 <div id="searchheader">
115 <h3>Results [% from %] to [% to %] of [% numresults %] found for [% IF ( member ) %]'<span class="ex">[% member %]</span>'[% END %][% IF ( surname ) %]'<span class="ex">[% surname %]</span>'[% END %]</h3>
118 <a href="javascript:void(0)" onclick="$('.selection').prop('checked', true)">Select all</a>
120 <a href="javascript:void(0)" onclick="$('.selection').prop('checked', false)">Clear all</a>
123 <label for="add_to_patron_list_which">Add:</label>
124 <select id="add_to_patron_list_which" name="add_to_patron_list_which">
125 <option value="selected">Selected patrons</option>
126 <option value="all">All resultant patrons</option>
129 <label for="add_to_patron_list">to:</label>
130 <select id="add_to_patron_list" name="add_to_patron_list">
131 <option value=""></option>
132 [% IF patron_lists %]
133 <optgroup label="Patron lists:">
134 [% FOREACH pl IN patron_lists %]
135 <option value="[% pl.patron_list_id %]">[% pl.name %]</option>
140 <option value="new">[ New list ]</option>
143 <input type="text" id="new_patron_list" name="new_patron_list" id="new_patron_list" />
145 [% FOREACH key IN search_parameters.keys %]
146 <input type="hidden" name="[% key %]" value="[% search_parameters.$key %]" />
149 <input id="add_to_patron_list_submit" type="submit" class="submit" value="Save">
153 <div class="searchresults">
155 <table id="memberresultst">
164 <th>OD/Checkouts</th>
171 [% FOREACH resultsloo IN resultsloop %]
172 [% IF ( resultsloo.overdue ) %]
175 [% UNLESS ( loop.odd ) %]
176 <tr class="highlight">
181 <td><input type="checkbox" class="selection" name="borrowernumber" value="[% resultsloo.borrowernumber %]" /></td>
182 <td>[% resultsloo.cardnumber %]</td>
183 <td style="white-space: nowrap;">
184 <a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% resultsloo.borrowernumber %]">
185 [% INCLUDE 'patron-title.inc' borrowernumber = resultsloo.borrowernumber category_type = resultsloo.category_type firstname = resultsloo.firstname surname = resultsloo.surname othernames = resultsloo.othernames cardnumber = resultsloo.cardnumber invert_name = 1%]
187 [% IF ( resultsloo.streetnumber ) %][% resultsloo.streetnumber %] [% END %][% resultsloo.address %][% IF ( resultsloo.address2 ) %]<br />[% resultsloo.address2 %][% END %][% IF ( resultsloo.city ) %]<br />[% resultsloo.city %][% IF ( resultsloo.state ) %],[% END %][% END %][% IF ( resultsloo.state ) %] [% resultsloo.state %][% END %] [% IF ( resultsloo.zipcode ) %] [% resultsloo.zipcode %][% END %][% IF ( resultsloo.country ) %], [% resultsloo.country %][% END %]</td>
188 <td>[% resultsloo.category_description %] ([% resultsloo.category_type %])</td>
189 <td>[% resultsloo.branchname %]</td>
190 <td>[% resultsloo.dateexpiry %]</td>
191 <td>[% IF ( resultsloo.overdues ) %]<span class="overdue"><strong>[% resultsloo.overdues %]</strong></span>[% ELSE %][% resultsloo.overdues %][% END %]/[% resultsloo.issues %]</td>
192 <td>[% IF ( resultsloo.fines < 0 ) %]<span class="credit">[% resultsloo.fines %]</span> [% ELSIF resultsloo.fines > 0 %] <span class="debit"><strong>[% resultsloo.fines %]</strong></span> [% ELSE %] [% resultsloo.fines %] [% END %]</td>
193 <td>[% resultsloo.borrowernotes %]</td>
194 <td>[% IF ( resultsloo.category_type ) %]
195 <a href="/cgi-bin/koha/members/memberentry.pl?op=modify&destination=circ&borrowernumber=[% resultsloo.borrowernumber %]&category_type=[% resultsloo.category_type %]">Edit</a>
196 [% ELSE %] <!-- try with categorycode if no category_type -->
197 [% IF ( resultsloo.categorycode ) %]
198 <a href="/cgi-bin/koha/members/memberentry.pl?op=modify&destination=circ&borrowernumber=[% resultsloo.borrowernumber %]&categorycode=[% resultsloo.categorycode %]">Edit</a>
199 [% ELSE %] <!-- if no categorycode, set category_type to A by default -->
200 <a href="/cgi-bin/koha/members/memberentry.pl?op=modify&destination=circ&borrowernumber=[% resultsloo.borrowernumber %]&category_type=A">Edit</a>
207 <div class="pages">[% IF ( multipage ) %][% paginationbar %][% END %]</div>
211 [% IF ( searching ) %]
212 <div class="dialog alert">No results found</div>
220 [% INCLUDE 'members-menu.inc' %]
225 [% INCLUDE 'intranet-bottom.inc' %]