From 98884012cf98889e6ff394c535d6765784f3793e Mon Sep 17 00:00:00 2001 From: tipaul Date: Sat, 25 Oct 2003 08:46:27 +0000 Subject: [PATCH] minor fixes for bilbio deletion (still buggy) --- C4/Biblio.pm | 8 +++++--- C4/Breeding.pm | 1 + 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/C4/Biblio.pm b/C4/Biblio.pm index f5b769beaf..86a053f551 100644 --- a/C4/Biblio.pm +++ b/C4/Biblio.pm @@ -1,6 +1,9 @@ package C4::Biblio; # $Id$ # $Log$ +# Revision 1.67 2003/10/25 08:46:27 tipaul +# minor fixes for bilbio deletion (still buggy) +# # Revision 1.66 2003/10/17 10:02:56 tipaul # Indexing only words longer than 2 letters. Was >=2 before, & 2 letters words usually means nothing. # @@ -1826,7 +1829,6 @@ where biblioitemnumber = $biblioitemnumber"; sub OLDdelbiblio{ my ($dbh,$biblio)=@_; -# my $dbh=C4Connect; my $query="select * from biblio where biblionumber=$biblio"; my $sth=$dbh->prepare($query); $sth->execute; @@ -1838,7 +1840,6 @@ sub OLDdelbiblio{ $query .= "'$temp',"; } $query=~ s/\,$/\)/; -# print $query; $sth=$dbh->prepare($query); $sth->execute; $sth->finish; @@ -1848,7 +1849,6 @@ sub OLDdelbiblio{ $sth->finish; } $sth->finish; -# $dbh->disconnect; } # @@ -2125,6 +2125,8 @@ sub delbiblio { my ($biblio)=@_; my $dbh = C4::Context->dbh; &OLDdelbiblio($dbh,$biblio); + my $bibid = &MARCfind_MARCbibid_from_oldbiblionumber($dbh,$biblio); + &MARCdelbiblio($dbh,$bibid,0); } sub getitemtypes { diff --git a/C4/Breeding.pm b/C4/Breeding.pm index b2d83c72c8..d66dad20ec 100644 --- a/C4/Breeding.pm +++ b/C4/Breeding.pm @@ -71,6 +71,7 @@ sub ImportBreeding { my $notmarcrecord = 0; for (my $i=0;$i<=$#marcarray;$i++) { my $marcrecord = MARC::File::USMARC::decode($marcarray[$i]."\x1D"); + my @warnings = $marcrecord->warnings(); if (ref($marcrecord) eq undef) { $notmarcrecord++; } else { -- 2.39.5