Bugzilla – Attachment 72404 Details for
Bug 14769
Authorities merge: Set correct indicators in biblio field
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 14769: (Follow-up) Let blinddetail look at indicator values
Bug-14769-Follow-up-Let-blinddetail-look-at-indica.patch (text/plain), 3.15 KB, created by
Josef Moravec
on 2018-03-05 07:01:26 UTC
(
hide
)
Description:
Bug 14769: (Follow-up) Let blinddetail look at indicator values
Filename:
MIME Type:
Creator:
Josef Moravec
Created:
2018-03-05 07:01:26 UTC
Size:
3.15 KB
patch
obsolete
>From 2ba1b881cc96607895a9431ec2b771ab83afc300 Mon Sep 17 00:00:00 2001 >From: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >Date: Fri, 9 Feb 2018 12:18:10 +0100 >Subject: [PATCH] Bug 14769: (Follow-up) Let blinddetail look at indicator > values > >If the indicators are not controlled, blinddetail should not overwrite >what the user already entered. Very strictly seen, we could say that it >is outside the scope. But it is strongly related. > >Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >Tested with 100 and 600 in the cataloging editor. >For 100 the second indicator should not be overwritten. For 600 it should. >Also tested "ind2:" which should blank ind2. > >Signed-off-by: Josef Moravec <josef.moravec@gmail.com> >--- > authorities/blinddetail-biblio-search.pl | 10 ++++------ > .../prog/en/modules/authorities/blinddetail-biblio-search.tt | 8 ++++++-- > 2 files changed, 10 insertions(+), 8 deletions(-) > >diff --git a/authorities/blinddetail-biblio-search.pl b/authorities/blinddetail-biblio-search.pl >index 0146a66..13f5dc6 100755 >--- a/authorities/blinddetail-biblio-search.pl >+++ b/authorities/blinddetail-biblio-search.pl >@@ -105,8 +105,8 @@ if ($authid) { > push( @subfield_loop, { marc_subfield => 'w', marc_values => $relationship } ) if ( $relationship ); > > my $controlled_ind = $auth->controlled_indicators({ record => $record, biblio_tag => $tag_number }); >- $indicator1 = $controlled_ind->{ind1} // q{}; >- $indicator2 = $controlled_ind->{ind2} // q{}; >+ $indicator1 = $controlled_ind->{ind1}; >+ $indicator2 = $controlled_ind->{ind2}; > if( defined $controlled_ind->{sub2} ) { > my $v = $controlled_ind->{sub2}; > push @subfield_loop, { marc_subfield => '2', marc_values => [ $v ] }; >@@ -116,15 +116,13 @@ if ($authid) { > $template->param( "clear" => 1 ); > } > >-# Remove spaces in indicators >-$indicator1 =~ s/\s//g; >-$indicator2 =~ s/\s//g; >- > $template->param( > authid => $authid ? $authid : "", > index => $index, > tagid => $tagid, >+ update_ind1 => defined($indicator1), > indicator1 => $indicator1, >+ update_ind2 => defined($indicator2), > indicator2 => $indicator2, > SUBFIELD_LOOP => \@subfield_loop, > tag_number => $tag_number, >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/authorities/blinddetail-biblio-search.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/authorities/blinddetail-biblio-search.tt >index f6ab158..abb0c66 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/authorities/blinddetail-biblio-search.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/authorities/blinddetail-biblio-search.tt >@@ -82,8 +82,12 @@ > ); > [% END %] > var indicators = field_start.getElementsByClassName('indicator flat'); >- indicators[0].value="[% indicator1 %]"; >- indicators[1].value="[% indicator2 %]"; >+ [% IF update_ind1 %] >+ indicators[0].value="[% indicator1 %]"; >+ [% END %] >+ [% IF update_ind2 %] >+ indicators[1].value="[% indicator2 %]"; >+ [% END %] > [% END %] > > // browse all its subfields (clear and $9) >-- >2.1.4
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 14769
:
42197
|
69343
|
70948
|
70949
|
70950
|
70951
|
71338
|
71339
|
71340
|
71341
|
71342
|
71343
|
71351
|
71352
|
71353
|
71354
|
71355
|
71366
|
71374
|
71375
|
71376
|
71377
|
71378
|
71379
|
71380
|
71381
|
72398
|
72399
|
72400
|
72401
|
72402
|
72403
|
72404
|
73389
|
73773
|
73774
|
73775
|
73776
|
73777
|
73778
|
73779
|
74052