From efc21e6f47801503e55e3ba709a48c3f426f90ac Mon Sep 17 00:00:00 2001 From: Nick Clemens Date: Fri, 21 Jun 2019 16:18:15 +0000 Subject: [PATCH] Bug 23115: (follow-up) Move switches to a TT block Signed-off-by: Martin Renvoize --- .../bootstrap/en/includes/account-table.inc | 77 +++++++------------ 1 file changed, 29 insertions(+), 48 deletions(-) diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/includes/account-table.inc b/koha-tmpl/opac-tmpl/bootstrap/en/includes/account-table.inc index b7378ab313..4058d5576c 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/en/includes/account-table.inc +++ b/koha-tmpl/opac-tmpl/bootstrap/en/includes/account-table.inc @@ -28,30 +28,7 @@ [% END %] [% ACCOUNT_LINE.date | $KohaDates %] - [% SWITCH ACCOUNT_LINE.accounttype %] - [% CASE 'Pay' %]Payment - [% CASE 'Pay00' %]Payment (cash via SIP2) - [% CASE 'Pay01' %]Payment (VISA via SIP2) - [% CASE 'Pay02' %]Payment (credit card via SIP2) - [% CASE 'VOID' %]Voided - [% CASE 'N' %]New card - [% CASE 'OVERDUE' %]Fine - [% CASE 'A' %]Account management fee - [% CASE 'M' %]Sundry - [% CASE 'L' %]Lost item - [% CASE 'W' %]Writeoff - [% CASE 'HE' %]Hold waiting too long - [% CASE 'Rent' %]Rental fee - [% CASE 'FOR' %]Forgiven - [% CASE 'LR' %]Lost item fee refund - [% CASE 'PF' %]Lost item processing fee - [% CASE 'PAY' %]Payment - [% CASE 'WO' %]Writeoff - [% CASE 'C' %]Credit - [% CASE 'CR' %]Credit - [%-CASE 'Res' %]Hold fee - [% CASE %][% ACCOUNT_LINE.accounttype | html %] - [%- END -%] + [% PROCESS account_type_description account=ACCOUNT_LINE %] [%- PROCESS account_status_description account=ACCOUNT_LINE -%] @@ -81,30 +58,7 @@ [% IF ENABLE_OPAC_PAYMENTS %][% END %] [% outstanding_credit.date | $KohaDates %] - [% SWITCH outstanding_credit.accounttype %] - [% CASE 'Pay' %]Payment - [% CASE 'Pay00' %]Payment (cash via SIP2) - [% CASE 'Pay01' %]Payment (VISA via SIP2) - [% CASE 'Pay02' %]Payment (credit card via SIP2) - [% CASE 'VOID' %]Voided - [% CASE 'N' %]New card - [% CASE 'OVERDUE' %]Fine - [% CASE 'A' %]Account management fee - [% CASE 'M' %]Sundry - [% CASE 'L' %]Lost item - [% CASE 'W' %]Writeoff - [% CASE 'HE' %]Hold waiting too long - [% CASE 'Rent' %]Rental fee - [% CASE 'FOR' %]Forgiven - [% CASE 'LR' %]Lost item fee refund - [% CASE 'PF' %]Lost item processing fee - [% CASE 'PAY' %]Payment - [% CASE 'WO' %]Writeoff - [% CASE 'C' %]Credit - [% CASE 'CR' %]Credit - [%-CASE 'Res' %]Hold fee - [% CASE %][% outstanding_credit.accounttype | html %] - [%- END -%] + [% PROCESS account_type_description account=outstanding_credit %] [%- PROCESS account_status_description account=outstanding_credit -%] @@ -162,6 +116,33 @@

You have no fines or charges

[% END %] +[%- BLOCK account_type_description -%] + [%- SWITCH account.accounttype -%] + [%- CASE 'Pay' -%]Payment + [%- CASE 'Pay00' -%]Payment (cash via SIP2) + [%- CASE 'Pay01' -%]Payment (VISA via SIP2) + [%- CASE 'Pay02' -%]Payment (credit card via SIP2) + [%- CASE 'N' -%]New card + [%- CASE 'OVERDUE' -%]Fine + [%- CASE 'A' -%]Account management fee + [%- CASE 'M' -%]Sundry + [%- CASE 'L' -%]Lost item + [%- CASE 'W' -%]Writeoff + [%- CASE 'HE' -%]Hold waiting too long + [%- CASE 'Rent' -%]Rental fee + [%- CASE 'FOR' -%]Forgiven + [%- CASE 'LR' -%]Lost item fee refund + [%- CASE 'PF' -%]Lost item processing fee + [%- CASE 'PAY' -%]Payment + [%- CASE 'WO' -%]Writeoff + [%- CASE 'C' -%]Credit + [%- CASE 'CR' -%]Credit + [%- CASE 'Res' -%]Hold fee + [%- CASE -%][% account.accounttype | html %] + [%- END -%] + [%- PROCESS account_status_description account=account -%] +[%- END -%] + [%- BLOCK account_status_description -%] [%- SWITCH account.status -%] [%- CASE 'UNRETURNED' -%] (Accruing) -- 2.39.5