@@ -, +, @@ allow patrons to use their library card number in addition to username --- opac/opac-password-recovery.pl | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) --- a/opac/opac-password-recovery.pl +++ a/opac/opac-password-recovery.pl @@ -58,10 +58,10 @@ if ( $query->param('sendEmail') || $query->param('resendEmail') ) { my $borrower; my $search_results = []; - # Find the borrower by his userid or email + # Find the borrower by userid, card number, or email if ($username) { - $search_results = [ Koha::Patrons->search( { userid => $username } ) ]; - $resultCount = Koha::Patrons->search( { userid => $username } ) -> count + $search_results = [ Koha::Patrons->search( { -or => { userid => $username, cardnumber => $username } } ) ]; + $resultCount = Koha::Patrons->search( { -or => { userid => $username, cardnumber => $username } } ) -> count } elsif ($email) { $search_results = [ Koha::Patrons->search( { -or => { email => $email, emailpro => $email, B_email => $email } } ) ]; --