Bug 17100: Do not display payments if patron has nothing to pay
[koha-ffzg.git] / members / summary-print.pl
index f1933f5..82b1ca2 100755 (executable)
@@ -46,11 +46,6 @@ my $data = GetMember( 'borrowernumber' => $borrowernumber );
 
 my ( $total, $accts, $numaccts ) = GetMemberAccountRecords($borrowernumber);
 foreach my $accountline (@$accts) {
-    $accountline->{amount} = sprintf( '%.2f', $accountline->{amount} )
-        if ( $accountline->{amount} ) ;
-    $accountline->{amountoutstanding} = sprintf( '%.2f', $accountline->{amountoutstanding} )
-        if ( $accountline->{amountoutstanding} );
-
     if (   $accountline->{accounttype} ne 'F'
         && $accountline->{accounttype} ne 'FU' )
     {
@@ -59,8 +54,6 @@ foreach my $accountline (@$accts) {
 }
 
 our $totalprice = 0;
-my $total_format = '';
-$total_format = sprintf( "%.2f", $total ) if ($total);
 
 my $holds_rs = Koha::Holds->search(
     { borrowernumber => $borrowernumber },
@@ -72,7 +65,7 @@ $template->param(
     borrowernumber => $borrowernumber,
 
     accounts => $accts,
-    totaldue => $total_format,
+    totaldue => $total,
 
     issues     => build_issue_data( GetPendingIssues($borrowernumber) ),
     totalprice => $totalprice,