From e68d3d988497289656bcf12b7f260cdc91cbc176 Mon Sep 17 00:00:00 2001 From: Owen Leonard Date: Fri, 5 Oct 2018 12:50:26 +0000 Subject: [PATCH] Bug 21497: Correctly format dates for ILL requests in OPAC This patch updates the opac ILL template to use the $KohaDates plugin for displaying dates. Also updated: - Added "title-string" sorting to allow for correct sorting of dates in the table of requests. - Corrected capitalization as per our capitalization rules. - Added self-closing / to inputs as per coding guidelines. To test, apply the patch and log in to the OPAC as a user who has multiple outstanding ILL requests. - In the table of ILL requests, the "Request placed" and "Last updated" dates should be formatted according to your system's dateformat preference. - Sorting of those columns should work correctly. - View a request and confirm that "Request placed" and "Last updated" dates in this view are also formatted correctly. Signed-off-by: Mark Tompsett Signed-off-by: Jonathan Druart Signed-off-by: Nick Clemens (cherry picked from commit a2418f743ce1e14d32229b5dd8d05aeb13f9e664) Signed-off-by: Martin Renvoize --- .../bootstrap/en/modules/opac-illrequests.tt | 31 ++++++++++--------- 1 file changed, 16 insertions(+), 15 deletions(-) diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-illrequests.tt b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-illrequests.tt index 116594cc1f..68ad487fd5 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-illrequests.tt +++ b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-illrequests.tt @@ -1,7 +1,8 @@ [% USE Koha %] +[% USE KohaDates %] [% USE Branches %] [% INCLUDE 'doc-head-open.inc' %] -[% IF ( LibraryNameTitle ) %][% LibraryNameTitle %][% ELSE %]Koha online[% END %] catalog › Your Interlibrary loan requests[% INCLUDE 'doc-head-close.inc' %] +[% IF ( LibraryNameTitle ) %][% LibraryNameTitle | html %][% ELSE %]Koha online[% END %] catalog › Your interlibrary loan requests[% INCLUDE 'doc-head-close.inc' %] [% BLOCK cssinclude %][% END %] [% INCLUDE 'bodytag.inc' bodyid='opac-illrequests' bodyclass='scrollto' %] @@ -23,9 +24,9 @@ [% IF method != 'list' %]
  • Interlibrary loan requests
  • [% IF method == 'create' %] -
  • New Interlibrary loan request
  • +
  • New interlibrary loan request
  • [% ELSIF method == 'view' %] -
  • View Interlibrary loan request
  • +
  • View interlibrary loan request
  • [% END %] [% ELSE %]
  • Interlibrary loan requests
  • @@ -53,7 +54,7 @@ [% ELSE %]
    [% IF method == 'create' %] -

    New Interlibrary loan request

    +

    New interlibrary loan request

    [% IF stage == 'copyrightclearance' %] [% INCLUDE messages %]
    @@ -78,8 +79,8 @@
    - - + +
    [% ELSE %] @@ -115,8 +116,8 @@ Requested from Request type Status - Request placed - Last updated + Request placed + Last updated @@ -129,8 +130,8 @@ [% request.backend %] [% request.medium %] [% request.capabilities.$status.name %] - [% request.placed %] - [% request.updated %] + [% request.placed | $KohaDates %] + [% request.updated | $KohaDates %] View @@ -139,7 +140,7 @@ [% ELSIF method == 'view' %] -

    View Interlibrary loan request

    +

    View interlibrary loan request

    [% INCLUDE messages %] [% status = request.status %]
    @@ -170,11 +171,11 @@
  • - [% request.placed %] + [% request.placed | $KohaDates %]
  • - [% request.updated %] + [% request.updated | $KohaDates %]
  • @@ -196,13 +197,13 @@ [% END %]
  • - + [% IF !request.completed %] [% IF request.status == "NEW" %] Request cancellation [% END %] - + [% END %] Cancel
    -- 2.39.5