add DateTime as a proper rather than hidden dependency
authorivan <ivan>
Fri, 15 Dec 2006 00:56:12 +0000 (00:56 +0000)
committerivan <ivan>
Fri, 15 Dec 2006 00:56:12 +0000 (00:56 +0000)
htetc/handler.pl
httemplate/edit/process/cust_main.cgi

index 2d82673..cce39be 100644 (file)
@@ -97,6 +97,7 @@ sub handler
       use Date::Parse;
       use Time::Local;
       use Time::Duration;
       use Date::Parse;
       use Time::Local;
       use Time::Duration;
+      use DateTime::Format::Strptime;
       use Lingua::EN::Inflect qw(PL);
       use Tie::IxHash;
       use URI::Escape;
       use Lingua::EN::Inflect qw(PL);
       use Tie::IxHash;
       use URI::Escape;
index 789f295..752bc95 100755 (executable)
@@ -57,8 +57,6 @@
 %}
 %
 %if ( $cgi->param('birthdate') && $cgi->param('birthdate') =~ /^([ 0-9\-\/]{0,10})$/ ) {
 %}
 %
 %if ( $cgi->param('birthdate') && $cgi->param('birthdate') =~ /^([ 0-9\-\/]{0,10})$/ ) {
-%  eval "use DateTime::Format::Strptime;";
-%  die $@ if $@;
 %  my $conf = new FS::Conf;
 %  my $format = $conf->config('date_format') || "%m/%d/%Y";
 %  my $parser = DateTime::Format::Strptime->new(pattern => $format,
 %  my $conf = new FS::Conf;
 %  my $format = $conf->config('date_format') || "%m/%d/%Y";
 %  my $parser = DateTime::Format::Strptime->new(pattern => $format,