+ return DateTime->today_local if lc($string) eq 'today';
+ return DateTime->today_local->subtract(days => 1) if lc($string) eq 'yesterday';
+
+ $params{dateformat} ||= $::myconfig{dateformat} || 'yy-mm-dd';
+ $params{numberformat} ||= $::myconfig{numberformat} || '1,000.00';
+ my $num_separator = $params{numberformat} =~ m{,\d+$} ? ',' : '.';
+
+ my ($date_str, $time_str) = split m{\s+}, $string, 2;
+ my ($yy, $mm, $dd) = $self->parse_date(\%params, $date_str);
+
+ my ($hour, $minute, $second) = split m/:/, ($time_str || '');
+ $second ||= '0';
+
+ ($second, my $millisecond) = split quotemeta($num_separator), $second, 2;
+ $_ ||= 0 for ($hour, $minute, $millisecond);
+
+ $millisecond = substr $millisecond, 0, 3;
+ $millisecond .= '0' x (3 - length $millisecond);
+
+ return undef unless $yy && $mm && $dd;
+ return DateTime->new(year => $yy, month => $mm, day => $dd, hour => $hour * 1, minute => $minute * 1, second => $second * 1, nanosecond => $millisecond * 1000000);