Merge remote-tracking branch 'origin/new/bug_7921' into 3.10.x

This commit is contained in:
Paul Poulain 2012-11-12 14:45:25 +01:00
commit c283a6a6cd
2 changed files with 5 additions and 4 deletions

View File

@ -1199,13 +1199,14 @@ sub GetUsedMarcStructure {
($MARCfield,$MARCsubfield)=GetMarcFromKohaField($kohafield,$frameworkcode);
Returns the MARC fields & subfields mapped to the koha field
for the given frameworkcode
for the given frameworkcode or default framework if $frameworkcode is missing
=cut
sub GetMarcFromKohaField {
my ( $kohafield, $frameworkcode ) = @_;
return (0, undef) unless $kohafield and defined $frameworkcode;
my $kohafield = shift;
my $frameworkcode = shift || '';
return (0, undef) unless $kohafield;
my $relations = C4::Context->marcfromkohafield;
if ( my $mf = $relations->{$frameworkcode}->{$kohafield} ) {
return @$mf;

View File

@ -451,7 +451,7 @@ sub MARCfindbreeding {
if ( C4::Context->preference("z3950NormalizeAuthor")
and C4::Context->preference("z3950AuthorAuthFields") )
{
my ( $tag, $subfield ) = GetMarcFromKohaField("biblio.author");
my ( $tag, $subfield ) = GetMarcFromKohaField("biblio.author", '');
# my $summary = C4::Context->preference("z3950authortemplate");
my $auth_fields =