From 313f95bb4609a66271d920fd3505e6d0686dd3a1 Mon Sep 17 00:00:00 2001 From: Julian Maurice Date: Mon, 19 Mar 2012 15:18:27 +0100 Subject: [PATCH 8/8] Bug 7743: Update opac-readingrecord.pl to use KohaDates TT plugin --- .../prog/en/modules/opac-readingrecord.tt | 4 +++- opac/opac-readingrecord.pl | 5 ++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/koha-tmpl/opac-tmpl/prog/en/modules/opac-readingrecord.tt b/koha-tmpl/opac-tmpl/prog/en/modules/opac-readingrecord.tt index fc5be4c..5941369 100644 --- a/koha-tmpl/opac-tmpl/prog/en/modules/opac-readingrecord.tt +++ b/koha-tmpl/opac-tmpl/prog/en/modules/opac-readingrecord.tt @@ -1,3 +1,5 @@ +[% USE KohaDates %] + [% INCLUDE 'doc-head-open.inc' %][% LibraryNameTitle or "Koha Online" %] Catalog › Your checkout history [% INCLUDE 'doc-head-close.inc' %] @@ -82,7 +84,7 @@ You have never borrowed anything from this library. [% UNLESS ( noItemTypeImages ) %][% IF ( READING_RECOR.imageurl ) %][% END %][% END %] [% READING_RECOR.description %] [% READING_RECOR.itemcallnumber %] -[% IF ( READING_RECOR.returndate ) %][% READING_RECOR.returndate %][% ELSE %](Checked out)[% END %] +[% IF ( READING_RECOR.returndate ) %][% READING_RECOR.returndate | $KohaDates %][% ELSE %](Checked out)[% END %] [% END %] diff --git a/opac/opac-readingrecord.pl b/opac/opac-readingrecord.pl index 00a91db..c504e87 100755 --- a/opac/opac-readingrecord.pl +++ b/opac/opac-readingrecord.pl @@ -25,7 +25,6 @@ use C4::Auth; use C4::Koha; use C4::Biblio; use C4::Circulation; -use C4::Dates qw/format_date/; use C4::Members; use C4::Output; @@ -89,8 +88,8 @@ foreach my $issue (@{$issues} ) { $line{title} = $issue->{'title'}; $line{author} = $issue->{'author'}; $line{itemcallnumber} = $issue->{'itemcallnumber'}; - $line{date_due} = format_date( $issue->{'date_due'} ); - $line{returndate} = format_date( $issue->{'returndate'} ); + $line{date_due} = $issue->{'date_due'}; + $line{returndate} = $issue->{'returndate'}; $line{volumeddesc} = $issue->{'volumeddesc'}; $issue->{'itemtype'} = C4::Context->preference('item-level_itypes') ? $issue->{'itype'} : $issue->{'itemtype'}; if($issue->{'itemtype'}) { -- 1.7.9.1