Bugzilla – Attachment 120832 Details for
Bug 27837
Permanent location is reverted to location when location updated and permanent_location mapped to MARC field
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 27837: (follow-up) Do not check subfield unless tag defined
Bug-27837-follow-up-Do-not-check-subfield-unless-t.patch (text/plain), 1.23 KB, created by
Nick Clemens (kidclamp)
on 2021-05-11 11:09:41 UTC
(
hide
)
Description:
Bug 27837: (follow-up) Do not check subfield unless tag defined
Filename:
MIME Type:
Creator:
Nick Clemens (kidclamp)
Created:
2021-05-11 11:09:41 UTC
Size:
1.23 KB
patch
obsolete
>From 0cb03868d87082181d42000132057adb7012d15f Mon Sep 17 00:00:00 2001 >From: Nick Clemens <nick@bywatersolutions.com> >Date: Tue, 11 May 2021 11:08:17 +0000 >Subject: [PATCH] Bug 27837: (follow-up) Do not check subfield unless tag > defined > >This was causing extra warnings when the permanent_location field was >unmapped. > >We only need to check if there is a field defined as you can define a mapping >without both a field and subfield, so the existence of one implies the other >--- > C4/Items.pm | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > >diff --git a/C4/Items.pm b/C4/Items.pm >index 729c6e0b48..1f0d560e86 100644 >--- a/C4/Items.pm >+++ b/C4/Items.pm >@@ -305,7 +305,7 @@ sub ModItemFromMarc { > my $item = TransformMarcToKoha( $localitemmarc, $frameworkcode, 'items' ); > > my ( $perm_loc_tag, $perm_loc_subfield ) = C4::Biblio::GetMarcFromKohaField( "items.permanent_location" ); >- my $has_permanent_location = defined $item_marc->subfield( $perm_loc_tag, $perm_loc_subfield ); >+ my $has_permanent_location = defined $perm_loc_tag && defined $item_marc->subfield( $perm_loc_tag, $perm_loc_subfield ); > > # Retrieving the values for the fields that are not linked > my @mapped_fields = Koha::MarcSubfieldStructures->search( >-- >2.11.0
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 27837
:
117570
|
117572
|
117625
|
117626
|
117627
|
117628
|
117634
|
117728
|
117729
|
117730
|
117735
|
117738
|
120361
|
120362
|
120363
|
120364
|
120562
|
120563
|
120564
|
120565
|
120566
|
120616
|
120628
|
120629
|
120832
|
121044
|
121045
|
121046
|
121047
|
121048
|
121049
|
121050
|
121051
|
121052