diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/moremember-print.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/moremember-print.tt index 1c09a91f40..dc08222cbc 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/moremember-print.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/moremember-print.tt @@ -1,6 +1,7 @@ [% USE Koha %] [% USE Branches %] [% USE KohaDates %] +[% USE Price %] [% INCLUDE 'doc-head-open.inc' %] Summary for [% firstname %] [% surname %] ([% cardnumber %]) [% INCLUDE 'doc-head-close.inc' %] @@ -71,7 +72,7 @@ [% END %] - [% IF ( accounts && ( totaldue != '0.00' ) ) %] + [% IF accounts && ( totaldue < 0 || totaldue > 0 ) %] @@ -82,23 +83,24 @@ [% FOREACH account IN accounts %] - [% NEXT IF account.amountoutstanding == '0.00' %] - - - - - - + [% IF ( account.amountoutstanding < 0 ) || ( account.amountoutstanding > 0 ) %] + + + + + + + [% END %] [% END %] - +
Account fines and payments
- [% IF ( account.itemnumber ) %][% END %] - [% account.description %] [% IF ( account.printtitle ) %] [% account.title |html %][% END %] - [% IF ( account.itemnumber ) %][% END %] - [% account.date | $KohaDates %][% account.amount %][% account.amountoutstanding %]
+ [% IF ( account.itemnumber ) %][% END %] + [% account.description %] [% IF ( account.printtitle ) %] [% account.title |html %][% END %] + [% IF ( account.itemnumber ) %][% END %] + [% account.date | $KohaDates %][% account.amount | $Price %][% account.amountoutstanding | $Price %]
Total due[% totaldue %][% totaldue | $Price %]
diff --git a/members/summary-print.pl b/members/summary-print.pl index 1544d99b32..81aaf159e8 100755 --- a/members/summary-print.pl +++ b/members/summary-print.pl @@ -43,11 +43,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' ) { @@ -56,8 +51,6 @@ foreach my $accountline (@$accts) { } our $totalprice = 0; -my $total_format = ''; -$total_format = sprintf( "%.2f", $total ) if ($total); $template->param( %$data, @@ -65,7 +58,7 @@ $template->param( borrowernumber => $borrowernumber, accounts => $accts, - totaldue => $total_format, + totaldue => $total, issues => build_issue_data( GetPendingIssues($borrowernumber) ), totalprice => $totalprice,