[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Koha-cvs] CVS: koha/C4 Biblio.pm,1.29,1.30
From: |
Paul POULAIN |
Subject: |
[Koha-cvs] CVS: koha/C4 Biblio.pm,1.29,1.30 |
Date: |
Thu, 12 Dec 2002 13:26:46 -0800 |
Update of /cvsroot/koha/koha/C4
In directory sc8-pr-cvs1:/tmp/cvs-serv13740/C4
Modified Files:
Biblio.pm
Log Message:
YAB ! (Yet Another Bugfix) => related to biblio modif
(some warning cleaning too)
Index: Biblio.pm
===================================================================
RCS file: /cvsroot/koha/koha/C4/Biblio.pm,v
retrieving revision 1.29
retrieving revision 1.30
diff -C2 -r1.29 -r1.30
*** Biblio.pm 12 Dec 2002 16:35:00 -0000 1.29
--- Biblio.pm 12 Dec 2002 21:26:35 -0000 1.30
***************
*** 2,5 ****
--- 2,9 ----
# $Id$
# $Log$
+ # Revision 1.30 2002/12/12 21:26:35 tipaul
+ # YAB ! (Yet Another Bugfix) => related to biblio modif
+ # (some warning cleaning too)
+ #
# Revision 1.29 2002/12/12 16:35:00 tipaul
# adding authentification with Auth.pm and
***************
*** 455,459 ****
# pass the MARC::Record to this function, and it will create the records in
the marc tables
my ($dbh,$record,$biblionumber) = @_;
! warn "adding : ".$record->as_formatted();
# search for MARC biblionumber
$dbh->do("lock tables marc_biblio WRITE,marc_subfield_table WRITE,
marc_word WRITE, marc_blob_subfield WRITE, stopwords READ");
--- 459,463 ----
# pass the MARC::Record to this function, and it will create the records in
the marc tables
my ($dbh,$record,$biblionumber) = @_;
! # warn "adding : ".$record->as_formatted();
# search for MARC biblionumber
$dbh->do("lock tables marc_biblio WRITE,marc_subfield_table WRITE,
marc_word WRITE, marc_blob_subfield WRITE, stopwords READ");
***************
*** 476,480 ****
$subfields[$subfieldcount][1]
);
! warn "ADDING :$bibid,".
$field->tag().
$field->indicator(1).$field->indicator(2).",
--- 480,484 ----
$subfields[$subfieldcount][1]
);
! # warn "ADDING :$bibid,".
$field->tag().
$field->indicator(1).$field->indicator(2).",
***************
*** 548,553 ****
$row->{'subfieldvalue'}=$row2->{'subfieldvalue'};
}
! # warn "$row->{bibid} = $row->{tag} - $row->{subfieldcode}";
! if ($row->{tagorder} ne $prevtagorder) {
if (length($prevtag) <3) {
$prevtag = "0".$prevtag;
--- 552,557 ----
$row->{'subfieldvalue'}=$row2->{'subfieldvalue'};
}
! # warn "$row->{bibid} = $row->{tag} - $row->{subfieldcode} ->
value : $row->{subfieldvalue}";
! if ($row->{tagorder} ne $prevtagorder || $row->{tag} ne
$prevtag) {
if (length($prevtag) <3) {
$prevtag = "0".$prevtag;
***************
*** 564,568 ****
%subfieldlist->{$row->{'subfieldcode'}} =
$row->{'subfieldvalue'};
} else {
! warn "subfieldcode : $row->{'subfieldcode'} / value :
$row->{'subfieldvalue'}, tag : $row->{tag}";
if (%subfieldlist->{$row->{'subfieldcode'}}) {
%subfieldlist->{$row->{'subfieldcode'}}.='|';
--- 568,572 ----
%subfieldlist->{$row->{'subfieldcode'}} =
$row->{'subfieldvalue'};
} else {
! # warn "subfieldcode : $row->{'subfieldcode'} / value :
$row->{'subfieldvalue'}, tag : $row->{tag}";
if (%subfieldlist->{$row->{'subfieldcode'}}) {
%subfieldlist->{$row->{'subfieldcode'}}.='|';
***************
*** 628,634 ****
my ($dbh,$record,$bibid,$itemnumber,$delete)address@hidden;
my $oldrecord=&MARCgetbiblio($dbh,$bibid);
! warn "OLD : ".$oldrecord->as_formatted();
! warn "----------------------------------\nNEW : ".$record->as_formatted();
! warn "\n";
# if nothing to change, don't waste time...
if ($oldrecord eq $record) {
--- 632,638 ----
my ($dbh,$record,$bibid,$itemnumber,$delete)address@hidden;
my $oldrecord=&MARCgetbiblio($dbh,$bibid);
! # warn "OLD : ".$oldrecord->as_formatted();
! # warn "----------------------------------\nNEW :
".$record->as_formatted();
! # warn "\n";
# if nothing to change, don't waste time...
if ($oldrecord eq $record) {
***************
*** 670,675 ****
return;
}
! warn "MARCmoditem : ".$record->as_formatted;
! warn "OLD : ".$oldrecord->as_formatted;
# otherwise, skip through each subfield...
--- 674,679 ----
return;
}
! # warn "MARCmoditem : ".$record->as_formatted;
! # warn "OLD : ".$oldrecord->as_formatted;
# otherwise, skip through each subfield...
***************
*** 685,693 ****
foreach my $subfield (@subfields) {
$subfieldorder++;
! warn "compare :
$oldfield".$oldfield->subfield(@$subfield[0]);
if ($oldfield eq 0 or
(length($oldfield->subfield(@$subfield[0])) ==0) ) {
# just adding datas...
# warn "addfield : / $subfieldorder / @$subfield[0] -
@$subfield[1]";
! warn "NEW subfield :
$bibid,".$field->tag().",".$tagorder.","address@hidden",".$subfieldorder.","address@hidden")";
&MARCaddsubfield($dbh,$bibid,$field->tag(),$field->indicator(1).$field->indicator(2),
$tagorder,@$subfield[0],$subfieldorder,@$subfield[1]);
--- 689,697 ----
foreach my $subfield (@subfields) {
$subfieldorder++;
! # warn "compare :
$oldfield".$oldfield->subfield(@$subfield[0]);
if ($oldfield eq 0 or
(length($oldfield->subfield(@$subfield[0])) ==0) ) {
# just adding datas...
# warn "addfield : / $subfieldorder / @$subfield[0] -
@$subfield[1]";
! # warn "NEW subfield :
$bibid,".$field->tag().",".$tagorder.","address@hidden",".$subfieldorder.","address@hidden")";
&MARCaddsubfield($dbh,$bibid,$field->tag(),$field->indicator(1).$field->indicator(2),
$tagorder,@$subfield[0],$subfieldorder,@$subfield[1]);
***************
*** 697,701 ****
if ($oldfield->subfield(@$subfield[0]) ne
@$subfield[1] ) {
my
$subfieldid=&MARCfindsubfieldid($dbh,$bibid,$field->tag(),$tagorder,@$subfield[0],$subfieldorder);
! warn "changing : $subfieldid,
$bibid,".$field->tag(),",$tagorder,@$subfield[0],@$subfield[1],$subfieldorder";
&MARCmodsubfield($dbh,$subfieldid,@$subfield[1]);
} else {
--- 701,705 ----
if ($oldfield->subfield(@$subfield[0]) ne
@$subfield[1] ) {
my
$subfieldid=&MARCfindsubfieldid($dbh,$bibid,$field->tag(),$tagorder,@$subfield[0],$subfieldorder);
! # warn "changing : $subfieldid,
$bibid,".$field->tag(),",$tagorder,@$subfield[0],@$subfield[1],$subfieldorder";
&MARCmodsubfield($dbh,$subfieldid,@$subfield[1]);
} else {
***************
*** 706,710 ****
}
}
- warn "-----------------------";
}
--- 710,713 ----
***************
*** 925,929 ****
%subfieldlist={};
%subfieldlist->address@hidden = @$rvalues[$i];
- warn " ==>@$rsubfields[$i]} = @$rvalues[$i];";
} else {
# if (%subfieldlist->address@hidden) {
--- 928,931 ----
***************
*** 932,936 ****
%subfieldlist->address@hidden address@hidden;
$prevtag= @$rtags[$i];
- warn " ==>@$rsubfields[$i]} ,= @$rvalues[$i];";
}
}
--- 934,937 ----
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Koha-cvs] CVS: koha/C4 Biblio.pm,1.29,1.30,
Paul POULAIN <=
- Prev by Date:
[Koha-cvs] CVS: koha/value_builder unimarc_field_100.pl,1.3,1.4 unimarc_field_225a.pl,1.1,1.2 unimarc_field_700-4.pl,1.2,1.3 unimarc_field_700_701_702.pl,1.1,1.2
- Next by Date:
[Koha-cvs] CVS: koha/misc Install.pm,NONE,1.1 installer.pl,1.4,1.5 koha.upgrade,1.1,1.2
- Previous by thread:
[Koha-cvs] CVS: koha/value_builder unimarc_field_100.pl,1.3,1.4 unimarc_field_225a.pl,1.1,1.2 unimarc_field_700-4.pl,1.2,1.3 unimarc_field_700_701_702.pl,1.1,1.2
- Next by thread:
[Koha-cvs] CVS: koha/misc Install.pm,NONE,1.1 installer.pl,1.4,1.5 koha.upgrade,1.1,1.2
- Index(es):