From 5e179f91d21f9d496d16bfb2f5d8c130809b0436 Mon Sep 17 00:00:00 2001 From: Nick Clemens Date: Wed, 19 Jul 2017 14:10:05 +0000 Subject: [PATCH] Bug 17182: Allow Keyword to MARC mapping for acquisitions searches This patchset adds the 'subtitle' field to the results display on acquistions search for adding an order form an existing item. Any field mapped to 'subtitle' in 'Keyword to MARC mapping' will be fetched and displayed in the results To test: 1 - Perform an acquisitions search for existing record 2 - Note record subtitles are not displayed 3 - Map 245$b and 245$n to 'subtitle' in 'Keyword to MARC mapping' 4 - Note they are still not displayed ion acq results 5 - Apply patch 6 - subtitle fields should now display Sponsored by: Round Rock Public Library Signed-off-by: Owen Leonard Signed-off-by: Julian Maurice Signed-off-by: Jonathan Druart Signed-off-by: Nick Clemens --- acqui/neworderbiblio.pl | 1 + koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderbiblio.tt | 1 + 2 files changed, 2 insertions(+) diff --git a/acqui/neworderbiblio.pl b/acqui/neworderbiblio.pl index 2e65569b15..beaa4da217 100755 --- a/acqui/neworderbiblio.pl +++ b/acqui/neworderbiblio.pl @@ -127,6 +127,7 @@ my @results; foreach my $result ( @{$marcresults} ) { my $marcrecord = C4::Search::new_record_from_zebra( 'biblioserver', $result ); my $biblio = TransformMarcToKoha( $marcrecord, '' ); + $biblio->{subtitles} = GetRecordValue( 'subtitle', GetMarcBiblio( $biblio->{biblionumber} ), GetFrameworkCode( $biblio->{biblionumber} ) ); $biblio->{booksellerid} = $booksellerid; push @results, $biblio; diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderbiblio.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderbiblio.tt index 3796d18363..bf2dd47d2d 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderbiblio.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderbiblio.tt @@ -75,6 +75,7 @@

[% biblio.title | html %] + [% FOREACH subtitle IN biblio.subtitles %] [% subtitle.subfield %][% END %] [% IF ( biblio.author ) %] by [% biblio.author %],[% END %]

[% IF ( biblio.isbn ) %] [% biblio.isbn %][% END %] [% IF ( biblio.pages ) %] - [% biblio.pages %][% END %] -- 2.39.5