GetMarcFromKohaField needs 2 args, or there's no point.
GetMarcFromKohaField returns (0,0) without the $frameworkcode argument. Note the argument can be "", but it must not be undefined. Signed-off-by: Galen Charlton <galen.charlton@liblime.com>
This commit is contained in:
parent
eaa3ee40a7
commit
6b9b778b1b
2 changed files with 9 additions and 11 deletions
|
@ -2217,7 +2217,7 @@ sub _DelBiblioNoZebra {
|
|||
if ($server eq 'biblioserver') {
|
||||
%index=GetNoZebraIndexes;
|
||||
# get title of the record (to store the 10 first letters with the index)
|
||||
my ($titletag,$titlesubfield) = GetMarcFromKohaField('biblio.title');
|
||||
my ($titletag,$titlesubfield) = GetMarcFromKohaField('biblio.title', ''); # FIXME: should be GetFrameworkCode($biblionumber) ??
|
||||
$title = lc($record->subfield($titletag,$titlesubfield));
|
||||
} else {
|
||||
# for authorities, the "title" is the $a mainentry
|
||||
|
@ -2311,7 +2311,7 @@ sub _AddBiblioNoZebra {
|
|||
if ($server eq 'biblioserver') {
|
||||
%index=GetNoZebraIndexes;
|
||||
# get title of the record (to store the 10 first letters with the index)
|
||||
my ($titletag,$titlesubfield) = GetMarcFromKohaField('biblio.title');
|
||||
my ($titletag,$titlesubfield) = GetMarcFromKohaField('biblio.title', ''); # FIXME: should be GetFrameworkCode($biblionumber) ??
|
||||
$title = lc($record->subfield($titletag,$titlesubfield));
|
||||
} else {
|
||||
# warn "server : $server";
|
||||
|
|
14
C4/Search.pm
14
C4/Search.pm
|
@ -1947,15 +1947,13 @@ sub NZorder {
|
|||
my ( $biblionumber, $title ) = split /,/, $_;
|
||||
my $record = GetMarcBiblio($biblionumber);
|
||||
my $callnumber;
|
||||
my ( $callnumber_tag, $callnumber_subfield ) =
|
||||
GetMarcFromKohaField( $dbh, 'items.itemcallnumber' );
|
||||
( $callnumber_tag, $callnumber_subfield ) =
|
||||
GetMarcFromKohaField('biblioitems.callnumber')
|
||||
my $frameworkcode = GetFrameworkCode($biblionumber);
|
||||
my ( $callnumber_tag, $callnumber_subfield ) = GetMarcFromKohaField( 'items.itemcallnumber', $frameworkcode);
|
||||
( $callnumber_tag, $callnumber_subfield ) = GetMarcFromKohaField('biblioitems.callnumber', $frameworkcode)
|
||||
unless $callnumber_tag;
|
||||
if ( C4::Context->preference('marcflavour') eq 'UNIMARC' ) {
|
||||
$callnumber = $record->subfield( '200', 'f' );
|
||||
}
|
||||
else {
|
||||
} else {
|
||||
$callnumber = $record->subfield( '100', 'a' );
|
||||
}
|
||||
|
||||
|
@ -2169,8 +2167,8 @@ sub ModBiblios {
|
|||
$tag = $tag . $subfield;
|
||||
undef $subfield;
|
||||
}
|
||||
my ( $bntag, $bnsubf ) = GetMarcFromKohaField('biblio.biblionumber');
|
||||
my ( $itemtag, $itemsubf ) = GetMarcFromKohaField('items.itemnumber');
|
||||
my ( $bntag, $bnsubf ) = GetMarcFromKohaField('biblio.biblionumber', '');
|
||||
my ( $itemtag, $itemsubf ) = GetMarcFromKohaField('items.itemnumber', '');
|
||||
if ($tag eq $itemtag) {
|
||||
# do not allow the embedded item tag to be
|
||||
# edited from here
|
||||
|
|
Loading…
Reference in a new issue