Bug 17100: Restore previous logic
authorJonathan Druart <jonathan.druart@bugs.koha-community.org>
Mon, 15 Aug 2016 14:11:19 +0000 (15:11 +0100)
committerKyle M Hall <kyle@bywatersolutions.com>
Thu, 18 Aug 2016 16:14:28 +0000 (16:14 +0000)
There is no need to change the previous logic here, so let's restore it.

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
koha-tmpl/intranet-tmpl/prog/en/modules/members/moremember-print.tt

index 93b59d4..66f13d7 100644 (file)
@@ -94,7 +94,7 @@
             [% END %]
         </table>
     [% END %]
-    [% IF accounts && ( totaldue < 0 || totaldue > 0 ) %]
+    [% IF accounts && totaldue != 0 %]
         <table>
             <caption>Account fines and payments</caption>
             <tr>
             </tr>
 
             [% FOREACH account IN accounts %]
-                [% IF ( account.amountoutstanding < 0 ) || ( account.amountoutstanding > 0 ) %]
-                    <tr>
-                        <td>
-                            [% IF ( account.itemnumber ) %]<a href="/cgi-bin/koha/catalogue/moredetail.pl?biblionumber=[% account.biblionumber %]&amp;itemnumber=[% account.itemnumber %]">[% END %]
-                            [% account.description %]&nbsp;[% IF ( account.printtitle ) %] [% account.title |html %][% END %]
-                            [% IF ( account.itemnumber ) %]</a>[% END %]
-                        </td>
-                        <td>[% account.date | $KohaDates %]</td>
-                        <td style="text-align:right;">[% account.amount | $Price %]</td>
-                        <td style="text-align:right;">[% account.amountoutstanding | $Price %]</td>
-                    </tr>
-                [% END %]
+                [% NEXT IF account.amountoutstanding == 0 %]
+                <tr>
+                    <td>
+                        [% IF ( account.itemnumber ) %]<a href="/cgi-bin/koha/catalogue/moredetail.pl?biblionumber=[% account.biblionumber %]&amp;itemnumber=[% account.itemnumber %]">[% END %]
+                        [% account.description %]&nbsp;[% IF ( account.printtitle ) %] [% account.title |html %][% END %]
+                        [% IF ( account.itemnumber ) %]</a>[% END %]
+                    </td>
+                    <td>[% account.date | $KohaDates %]</td>
+                    <td style="text-align:right;">[% account.amount | $Price %]</td>
+                    <td style="text-align:right;">[% account.amountoutstanding | $Price %]</td>
+                </tr>
             [% END %]
 
             <tfoot>