From f317f8019385179873f5e1b02ea72df60730894b Mon Sep 17 00:00:00 2001 From: Kyle M Hall <kyle@bywatersolutions.com> Date: Thu, 24 Sep 2015 08:11:03 -0400 Subject: [PATCH] Bug 11622 [QA Follouwp] - Display payment block only if there is something to pay Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- .../opac-tmpl/bootstrap/en/modules/opac-account.tt | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-) diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-account.tt b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-account.tt index 7bf893c..a5723d7 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-account.tt +++ b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-account.tt @@ -1,6 +1,7 @@ [% USE Koha %] [% USE KohaDates %] [% SET ENABLE_OPAC_PAYMENTS = Koha.Preference('EnablePayPalOpacPayments') %] +[% SET DISPLAY_PAYMENT_BLOCK = 0 %] [% INCLUDE 'doc-head-open.inc' %] <title>[% IF ( LibraryNameTitle ) %][% LibraryNameTitle %][% ELSE %]Koha online[% END %] catalog › Your fines and charges</title> @@ -93,6 +94,7 @@ [% IF ENABLE_OPAC_PAYMENTS %] <td> [% IF ACCOUNT_LINE.amountoutstanding > 0 %] + [% SET DISPLAY_PAYMENT_BLOCK = 1 %] <input class="checkbox-pay pay-online hidden" name="accountline" type="checkbox" id="checkbox-pay-[% ACCOUNT_LINE.accountlines_id %]" value="[% ACCOUNT_LINE.accountlines_id %]"> <input type="hidden" id="amount-[% ACCOUNT_LINE.accountlines_id %]" value="[% ACCOUNT_LINE.amountoutstanding %]" /> [% END %] @@ -132,7 +134,7 @@ </table> - [% IF ENABLE_OPAC_PAYMENTS %] + [% IF ENABLE_OPAC_PAYMENTS && DISPLAY_PAYMENT_BLOCK %] <fieldset class="pay-online hidden"> <legend>Pay selected fines and charges</legend> <span class="help-block"><h3>Payment method</h3></span> -- 1.7.2.5