Fixing a problem that was causing double conversion of dates
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
This commit is contained in:
parent
753219b79d
commit
5d0a5eb01e
1 changed files with 6 additions and 3 deletions
|
@ -656,9 +656,12 @@ sub AddMember {
|
|||
my $dbh = C4::Context->dbh;
|
||||
$data{'userid'} = '' unless $data{'password'};
|
||||
$data{'password'} = md5_base64( $data{'password'} ) if $data{'password'};
|
||||
$data{'dateofbirth'} = format_date_in_iso( $data{'dateofbirth'} );
|
||||
$data{'dateenrolled'} = format_date_in_iso( $data{'dateenrolled'});
|
||||
$data{'dateexpiry'} = format_date_in_iso( $data{'dateexpiry'} );
|
||||
|
||||
# WE SHOULD NEVER PASS THIS SUBROUTINE ANYTHING OTHER THAN ISO DATES
|
||||
# IF YOU UNCOMMENT THESE LINES YOU BETTER HAVE A DARN COMPELLING REASON
|
||||
# $data{'dateofbirth'} = format_date_in_iso( $data{'dateofbirth'} );
|
||||
# $data{'dateenrolled'} = format_date_in_iso( $data{'dateenrolled'});
|
||||
# $data{'dateexpiry'} = format_date_in_iso( $data{'dateexpiry'} );
|
||||
# This query should be rewritten to use "?" at execute.
|
||||
my $query =
|
||||
"insert into borrowers set cardnumber=" . $dbh->quote( $data{'cardnumber'} )
|
||||
|
|
Loading…
Reference in a new issue