* tools/modborrowers.pl (GetBorrowerInfos): Fix setting of patron
category description.
* koha-tmpl/intranet-tmpl/prog/en/modules/tools/modborrowers.tt: Use
it.
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
<td>[% borrower.surname %]</td>
<td>[% borrower.firstname %]</td>
<td>[% Branches.GetName( borrower.branchcode ) %]</td>
- <td>[% borrower.categorycode %]</td>
+ <td>[% borrower.category_description %]</td>
<td>[% borrower.city %]</td>
<td>[% borrower.state %]</td>
<td>[% borrower.zipcode %]</td>
sub GetBorrowerInfos {
my ( %info ) = @_;
my $borrower = Koha::Patrons->find( \%info );
+ my $catdesc = $borrower->category->description;
if ( $borrower ) {
$borrower = $borrower->unblessed;
for ( qw(dateenrolled dateexpiry) ) {
}
$borrower->{$_} = $userdate || '';
}
- $borrower->{category_description} = Koha::Patron::Categories->find( $borrower->{categorycode} )->{description};
+ $borrower->{category_description} = $catdesc;
my $attr_loop = C4::Members::Attributes::GetBorrowerAttributes( $borrower->{borrowernumber} );
$borrower->{patron_attributes} = $attr_loop;
}