Lines 139-146
output_html_with_http_headers $input, $cookie, $template->output;
Link Here
|
139 |
sub add_accounts_to_template { |
139 |
sub add_accounts_to_template { |
140 |
|
140 |
|
141 |
my $patron = Koha::Patrons->find( $borrowernumber ); |
141 |
my $patron = Koha::Patrons->find( $borrowernumber ); |
142 |
my $total = $patron->account->balance; |
142 |
my ( $total, $account_lines ) = Koha::Account->new( { patron_id => $borrowernumber } )->outstanding_debits; |
143 |
my $account_lines = Koha::Account::Lines->search({ borrowernumber => $borrowernumber, amountoutstanding => { '!=' => 0 } }, { order_by => ['accounttype'] }); |
|
|
144 |
my @accounts; |
143 |
my @accounts; |
145 |
while ( my $account_line = $account_lines->next ) { |
144 |
while ( my $account_line = $account_lines->next ) { |
146 |
$account_line = $account_line->unblessed; |
145 |
$account_line = $account_line->unblessed; |