[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Koha-cvs] CVS: koha/acqui.simple marcimport.pl,1.6.2.17,1.6.2.18
From: |
Alan Millar |
Subject: |
[Koha-cvs] CVS: koha/acqui.simple marcimport.pl,1.6.2.17,1.6.2.18 |
Date: |
Wed, 12 Jun 2002 13:25:37 -0700 |
Update of /cvsroot/koha/koha/acqui.simple
In directory usw-pr-cvs1:/tmp/cvs-serv22636
Modified Files:
Tag: rel-1-2
marcimport.pl
Log Message:
fix bug in arrayed subfields
Index: marcimport.pl
===================================================================
RCS file: /cvsroot/koha/koha/acqui.simple/marcimport.pl,v
retrieving revision 1.6.2.17
retrieving revision 1.6.2.18
diff -C2 -r1.6.2.17 -r1.6.2.18
*** marcimport.pl 10 Jun 2002 06:47:17 -0000 1.6.2.17
--- marcimport.pl 12 Jun 2002 20:25:35 -0000 1.6.2.18
***************
*** 636,644 ****
if ( $fieldname=$tagmap{ $field->{'tag'} }->{$subfield}->{name}
) {
# Yes, so keep the value
! $bib->{$fieldname}=$field->{'subfields'}->{$subfield};
# if it was an array, just keep first element.
! if (ref($bib->{$fieldname}) eq 'ARRAY') {
! $bib->{$fieldname}=$$bib->{fieldname}[0]
} # if array
# see if this field should have trailing chars dropped
if ($strip=$tagmap{ $field->{'tag'}
}->{$subfield}->{striptrail} ) {
--- 636,646 ----
if ( $fieldname=$tagmap{ $field->{'tag'} }->{$subfield}->{name}
) {
# Yes, so keep the value
! if ( ref($field->{'subfields'}->{$subfield} ) eq 'ARRAY' ) {
# if it was an array, just keep first element.
!
$bib->{$fieldname}=$field->{'subfields'}->{$subfield}[0];
! } else {
! $bib->{$fieldname}=$field->{'subfields'}->{$subfield};
} # if array
+ print "$field->{'tag'} $subfield
$fieldname=$bib->{$fieldname}\n" if $debug;
# see if this field should have trailing chars dropped
if ($strip=$tagmap{ $field->{'tag'}
}->{$subfield}->{striptrail} ) {
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Koha-cvs] CVS: koha/acqui.simple marcimport.pl,1.6.2.17,1.6.2.18,
Alan Millar <=