Bugzilla – Attachment 121051 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.29 KB, created by
Martin Renvoize (ashimema)
on 2021-05-17 13:26:51 UTC
(
hide
)
Description:
Bug 27837: (follow-up) Do not check subfield unless tag defined
Filename:
MIME Type:
Creator:
Martin Renvoize (ashimema)
Created:
2021-05-17 13:26:51 UTC
Size:
1.29 KB
patch
obsolete
>From 467dae7a23a4b4ccbf0308adc467d68129d3fae2 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 > >Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> >--- > 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.20.1
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