From 106361a6296e6eed68ac0cf7b8fb998d28cbc46f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marc=20V=C3=A9ron?= Date: Sun, 15 Mar 2015 13:56:51 +0100 Subject: [PATCH] Bug 13813 - Remove C4::Dates from opac/opac-user.pl To test: Apply patch Manually restrict a patron (with end date) Check in to OPAC with this patron's username/password Verify that message about restrictions displays restriction date correctly in tab "Your summary" (opac-user.pl) --- opac/opac-user.pl | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/opac/opac-user.pl b/opac/opac-user.pl index 995db7b..724eb2f 100755 --- a/opac/opac-user.pl +++ b/opac/opac-user.pl @@ -293,7 +293,9 @@ foreach my $res (@reserves) { if ($show_priority) { $res->{'priority'} ||= ''; } - $res->{'suspend_until'} = C4::Dates->new( $res->{'suspend_until'}, "iso")->output("syspref") if ( $res->{'suspend_until'} ); + if ( $res->{'suspend_until'} ) { + $res->{'suspend_until'} = output_pref({ dt => dt_from_string( $res->{'suspend_until'} , 'iso' ), dateonly => 1 }); + } } # use Data::Dumper; -- 1.7.10.4