X-Git-Url: http://wagnertech.de/gitweb/gitweb.cgi/mfinanz.git/blobdiff_plain/dbda14c263efd93aca3b7114015a47d86b8581e3..931c8a6320097b9c0f6e7e098d2533b3a70d15db:/SL/Locale.pm diff --git a/SL/Locale.pm b/SL/Locale.pm index b6065da77..4fc7a5ee0 100644 --- a/SL/Locale.pm +++ b/SL/Locale.pm @@ -380,6 +380,17 @@ sub parse_date_to_object { return $yy && $mm && $dd ? DateTime->new(year => $yy, month => $mm, day => $dd) : undef; } +sub format_date_object_to_time { + my ($self, $datetime, %params) = @_; + + my $format = $::myconfig{timeformat} || 'hh:mm'; + $format =~ s/hh/\%H/; + $format =~ s/mm/\%M/; + $format =~ s/ss/\%S/; + + return $datetime->strftime($format); +} + sub format_date_object { my ($self, $datetime, %params) = @_;