Utilisation de localtime à la place de DateTime
This commit is contained in:
parent
273ea2ac0d
commit
5082d5e74f
|
@ -10,7 +10,6 @@
|
|||
#####################################################
|
||||
|
||||
use DBI;
|
||||
use DateTime;
|
||||
use strict;
|
||||
|
||||
#plugin level variables are here since version 0.02
|
||||
|
@ -68,7 +67,8 @@ $transaction->notes('log2sql_mail_id', $mail_id);
|
|||
# quote the mail_id for later use:
|
||||
$mail_id = $dbh->quote($mail_id);
|
||||
|
||||
my $dt = DateTime->now;
|
||||
my ($sec,$min,$hour,$day,$mon,$year) = localtime;
|
||||
$year += 1900;
|
||||
|
||||
my($statement) = "INSERT INTO ".$mail_table." (mail_id,".
|
||||
$mail_table.".date_day,".
|
||||
|
@ -76,8 +76,8 @@ my($statement) = "INSERT INTO ".$mail_table." (mail_id,".
|
|||
"remote_ip,remote_host,remote_info) ".
|
||||
"VALUES(".
|
||||
$mail_id.",".
|
||||
$dbh->quote($dt->ymd).",".
|
||||
$dbh->quote($dt->hms).",".
|
||||
$dbh->quote($year.'-'.$mon.'-'.$day).",".
|
||||
$dbh->quote($hour.':'.$min.':'.$sec).",".
|
||||
$dbh->quote($self->qp->connection->remote_ip).",".
|
||||
$dbh->quote($self->qp->connection->remote_host).",".
|
||||
$dbh->quote($self->qp->connection->remote_info).")";
|
||||
|
|
|
@ -17,7 +17,6 @@ BuildRequires: e-smith-devtools
|
|||
|
||||
Requires: smeserver-qpsmtpd
|
||||
Requires: e-smith-mysql
|
||||
Requires: perl(Date::Time)
|
||||
Requires: perl(DBI)
|
||||
|
||||
%description
|
||||
|
|
Loading…
Reference in New Issue