From 940e47ae09fbe1d7aada0657e50c9f23ff2430b7 Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Wed, 14 Nov 2018 09:38:01 -0300 Subject: [PATCH] Bug 21829: Correctly format dateexpiry in notices (date only) dateexpiry is a date, we should not display the time part in notice. Test plan: Create a notice with borrowers.dateexpiry, generate this notice. The value should be displayed without the time part Signed-off-by: Kyle M Hall --- C4/Letters.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/C4/Letters.pm b/C4/Letters.pm index 0f2378d660..bf94c0e2ba 100644 --- a/C4/Letters.pm +++ b/C4/Letters.pm @@ -785,7 +785,7 @@ sub _parseletter { my $values = $values_in ? { %$values_in } : {}; if ( $table eq 'borrowers' && $values->{'dateexpiry'} ){ - $values->{'dateexpiry'} = output_pref({ str => $values->{dateexpiry}, dateonly => 1 }); + $values->{'dateexpiry'} = output_pref({ dt => dt_from_string( $values->{'dateexpiry'} ), dateonly => 1 }); } if ( $table eq 'reserves' && $values->{'waitingdate'} ) { -- 2.17.2 (Apple Git-113)