Bugzilla – Attachment 138664 Details for
Bug 29897
Display author identifiers for researchers
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 29897: Rename get_marc_authors with get_marc_contributors
Bug-29897-Rename-getmarcauthors-with-getmarccontri.patch (text/plain), 6.12 KB, created by
Katrin Fischer
on 2022-08-05 10:55:13 UTC
(
hide
)
Description:
Bug 29897: Rename get_marc_authors with get_marc_contributors
Filename:
MIME Type:
Creator:
Katrin Fischer
Created:
2022-08-05 10:55:13 UTC
Size:
6.12 KB
patch
obsolete
>From a8d08b7566d69e6874af2fa4d147d26fa7d50ad0 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Mon, 17 Jan 2022 17:41:39 +0100 >Subject: [PATCH] Bug 29897: Rename get_marc_authors with get_marc_contributors > >get_marc_authors actually return authors from 700..712, not the first >author from 200 > >Sponsored-by: Orex Digital > >Signed-off-by: Orex Digital <info@orex.es> > >Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de> >--- > Koha/Biblio.pm | 10 +++++----- > basket/basket.pl | 2 +- > basket/sendbasket.pl | 2 +- > opac/opac-basket.pl | 2 +- > opac/opac-sendbasket.pl | 2 +- > opac/opac-sendshelf.pl | 2 +- > t/db_dependent/Koha/Biblio.t | 4 ++-- > virtualshelves/sendshelf.pl | 2 +- > 8 files changed, 13 insertions(+), 13 deletions(-) > >diff --git a/Koha/Biblio.pm b/Koha/Biblio.pm >index 5a1be3cfe2..56edb03d8b 100644 >--- a/Koha/Biblio.pm >+++ b/Koha/Biblio.pm >@@ -1001,16 +1001,16 @@ sub get_marc_notes { > return \@marcnotes; > } > >-=head3 get_marc_authors >+=head3 get_marc_contributors > >- my $authors = $biblio->get_marc_authors; >+ my $contributors = $biblio->get_marc_contributors; > >-Get all authors from the MARC record and returns them in an array. >-The authors are stored in different fields depending on MARC flavour >+Get all contributors (but first author) from the MARC record and returns them in an array. >+They are stored in different fields depending on MARC flavour > > =cut > >-sub get_marc_authors { >+sub get_marc_contributors { > my ( $self, $params ) = @_; > > my ( $mintag, $maxtag, $fields_filter ); >diff --git a/basket/basket.pl b/basket/basket.pl >index 6f93e5a82b..fc69f5179d 100755 >--- a/basket/basket.pl >+++ b/basket/basket.pl >@@ -68,7 +68,7 @@ foreach my $biblionumber ( @bibs ) { > my $dat = $biblio->unblessed; > my $record = $biblio->metadata->record; > my $marcnotesarray = $biblio->get_marc_notes; >- my $marcauthorsarray = $biblio->get_marc_authors; >+ my $marcauthorsarray = $biblio->get_marc_contributors; > my $marcsubjctsarray = GetMarcSubjects( $record, $marcflavour ); > my $marcseriesarray = GetMarcSeries ($record,$marcflavour); > my $marcurlsarray = GetMarcUrls ($record,$marcflavour); >diff --git a/basket/sendbasket.pl b/basket/sendbasket.pl >index c5bf9822fb..04882db160 100755 >--- a/basket/sendbasket.pl >+++ b/basket/sendbasket.pl >@@ -73,7 +73,7 @@ if ( $email_add ) { > my $biblio = Koha::Biblios->find( $biblionumber ) or next; > my $dat = $biblio->unblessed; > my $record = $biblio->metadata->record({ embed_items => 1 }); >- my $marcauthorsarray = $biblio->get_marc_authors; >+ my $marcauthorsarray = $biblio->get_marc_contributors; > my $marcsubjctsarray = GetMarcSubjects( $record, $marcflavour ); > > my @items = GetItemsInfo( $biblionumber ); >diff --git a/opac/opac-basket.pl b/opac/opac-basket.pl >index bf3e6f4817..f2eefd0bca 100755 >--- a/opac/opac-basket.pl >+++ b/opac/opac-basket.pl >@@ -84,7 +84,7 @@ foreach my $biblionumber ( @bibs ) { > $record_processor->process($record); > next unless $record; > my $marcnotesarray = $biblio->get_marc_notes({ opac => 1 }); >- my $marcauthorsarray = $biblio->get_marc_authors; >+ my $marcauthorsarray = $biblio->get_marc_contributors; > my $marcsubjctsarray = GetMarcSubjects( $record, $marcflavour ); > my $marcseriesarray = GetMarcSeries ($record,$marcflavour); > my $marcurlsarray = GetMarcUrls ($record,$marcflavour); >diff --git a/opac/opac-sendbasket.pl b/opac/opac-sendbasket.pl >index fcc49e0f7e..9448f21552 100755 >--- a/opac/opac-sendbasket.pl >+++ b/opac/opac-sendbasket.pl >@@ -85,7 +85,7 @@ if ( $email_add ) { > patron => $patron, > } > ); >- my $marcauthorsarray = $biblio->get_marc_authors; >+ my $marcauthorsarray = $biblio->get_marc_contributors; > my $marcsubjctsarray = GetMarcSubjects( $record, $marcflavour ); > > my @items = GetItemsInfo( $biblionumber ); >diff --git a/opac/opac-sendshelf.pl b/opac/opac-sendshelf.pl >index 915428111a..817c1069a9 100755 >--- a/opac/opac-sendshelf.pl >+++ b/opac/opac-sendshelf.pl >@@ -94,7 +94,7 @@ if ( $shelf and $shelf->can_be_viewed( $borrowernumber ) ) { > next unless $record; > my $fw = GetFrameworkCode($biblionumber); > >- my $marcauthorsarray = $biblio->get_marc_authors; >+ my $marcauthorsarray = $biblio->get_marc_contributors; > my $marcsubjctsarray = GetMarcSubjects( $record, $marcflavour ); > > my @items = GetItemsInfo( $biblionumber ); >diff --git a/t/db_dependent/Koha/Biblio.t b/t/db_dependent/Koha/Biblio.t >index df9dffe0bd..f1633dedee 100755 >--- a/t/db_dependent/Koha/Biblio.t >+++ b/t/db_dependent/Koha/Biblio.t >@@ -881,7 +881,7 @@ subtest 'current_checkouts() and old_checkouts() tests' => sub { > $schema->storage->txn_rollback; > }; > >-subtest 'get_marc_authors() tests' => sub { >+subtest 'get_marc_contributors() tests' => sub { > > plan tests => 1; > >@@ -904,7 +904,7 @@ subtest 'get_marc_authors() tests' => sub { > C4::Biblio::ModBiblio( $record, $biblio->biblionumber ); > $biblio = Koha::Biblios->find( $biblio->biblionumber ); > >- is( 4, @{$biblio->get_marc_authors}, 'get_marc_authors retrieves correct number of author subfields' ); >+ is( 4, @{$biblio->get_marc_contributors}, 'get_marc_contributors retrieves correct number of author subfields' ); > $schema->storage->txn_rollback; > }; > >diff --git a/virtualshelves/sendshelf.pl b/virtualshelves/sendshelf.pl >index 0bcb43cea1..e87092884c 100755 >--- a/virtualshelves/sendshelf.pl >+++ b/virtualshelves/sendshelf.pl >@@ -80,7 +80,7 @@ if ($to_address) { > my $biblio = Koha::Biblios->find( $biblionumber ) or next; > my $dat = $biblio->unblessed; > my $record = $biblio->metadata->record({ embed_items => 1 }); >- my $marcauthorsarray = $biblio->get_marc_authors; >+ my $marcauthorsarray = $biblio->get_marc_contributors; > my $marcsubjctsarray = GetMarcSubjects( $record, $marcflavour ); > > my @items = GetItemsInfo($biblionumber); >-- >2.30.2
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 29897
:
129816
|
129817
|
129818
|
129819
|
132961
|
132962
|
132963
|
132964
|
133081
|
133113
|
133114
|
133115
|
133116
|
133117
|
134459
|
134460
|
134461
|
134462
|
134463
|
134464
|
135983
|
135984
|
135985
|
135986
|
135987
|
135988
|
135989
|
135990
|
135991
|
135992
|
135993
|
138249
|
138250
|
138251
|
138252
|
138253
|
138254
|
138255
|
138256
|
138257
|
138258
|
138259
|
138260
|
138371
|
138372
|
138425
|
138426
|
138427
|
138428
|
138429
|
138430
|
138431
|
138432
|
138433
|
138434
|
138435
|
138486
|
138487
|
138490
|
138501
| 138664 |
138665
|
138666
|
138667
|
138668
|
138669
|
138670
|
138671
|
138672
|
138673
|
138674
|
138675
|
138676
|
138677
|
138678
|
138679