From 86f6a4bc19af2e6ba521db6646036d3369b1adab Mon Sep 17 00:00:00 2001 From: Terran McCanna Date: Fri, 15 May 2015 10:18:15 -0700 Subject: [PATCH] LP1454879: Add Account Expiration Date to OPAC Added Account Expiration Date to OPAC My Account display on Account Summary page and Account Preferences page. This is in response to patron requests to know when their accounts will expire before the point at which they actually expire. To test, log into My Account through the OPAC - a new table row with account expiration date should appear on the main account summary page, and another new row should appear on the main account preferences page. Signed-off-by: Terran McCanna Signed-off-by: Josh Stompro Signed-off-by: Ben Shum --- Open-ILS/src/templates/opac/myopac/prefs.tt2 | 12 ++++++++++++ Open-ILS/src/templates/opac/parts/myopac/main_base.tt2 | 6 ++++++ 2 files changed, 18 insertions(+) diff --git a/Open-ILS/src/templates/opac/myopac/prefs.tt2 b/Open-ILS/src/templates/opac/myopac/prefs.tt2 index a8e1d19a20..f2462a5d6b 100644 --- a/Open-ILS/src/templates/opac/myopac/prefs.tt2 +++ b/Open-ILS/src/templates/opac/myopac/prefs.tt2 @@ -106,6 +106,18 @@ [% date.format(ctx.parse_datetime(ctx.user.create_date), DATE_FORMAT) %] + + [% l("Account Expiration Date") %] + + [%- IF date.format(ctx.parse_datetime(ctx.user.expire_date), '%s') < date.format(date.now , '%s'); -%] + [% date.format(ctx.parse_datetime(ctx.user.expire_date), DATE_FORMAT) %] + + [% ELSE %] + [% date.format(ctx.parse_datetime(ctx.user.expire_date), DATE_FORMAT) %] + [% END %] + + +

diff --git a/Open-ILS/src/templates/opac/parts/myopac/main_base.tt2 b/Open-ILS/src/templates/opac/parts/myopac/main_base.tt2 index 86f34887a1..bf84e80294 100644 --- a/Open-ILS/src/templates/opac/parts/myopac/main_base.tt2 +++ b/Open-ILS/src/templates/opac/parts/myopac/main_base.tt2 @@ -39,6 +39,12 @@ + + + +
[% l("Account Expiration Date") %] + [% date.format(ctx.parse_datetime(ctx.user.expire_date), DATE_FORMAT) %] +
[% l("Items Currently Checked out ([_1])", ctx.user_stats.checkouts.total_out) %]