Bugzilla – Attachment 68532 Details for
Bug 18153
UNIMARC bib records exported with invalid 'a' char in label pos.9
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 18153 : fix unimarc label in export tool
Bug-18153--fix-unimarc-label-in-export-tool.patch (text/plain), 1.25 KB, created by
Stéphane Delaune
on 2017-10-25 13:48:15 UTC
(
hide
)
Description:
Bug 18153 : fix unimarc label in export tool
Filename:
MIME Type:
Creator:
Stéphane Delaune
Created:
2017-10-25 13:48:15 UTC
Size:
1.25 KB
patch
obsolete
>From 3a3fd3fddc3f3c71f2406fcb150a3eaa7e0cd63b Mon Sep 17 00:00:00 2001 >From: Koha User <support@biblibre.com> >Date: Wed, 25 Oct 2017 15:44:56 +0200 >Subject: [PATCH] Bug 18153 : fix unimarc label in export tool > >--- > Koha/Exporter/Record.pm | 10 ++++++++++ > 1 file changed, 10 insertions(+) > >diff --git a/Koha/Exporter/Record.pm b/Koha/Exporter/Record.pm >index f9d62df..91c3ba2 100644 >--- a/Koha/Exporter/Record.pm >+++ b/Koha/Exporter/Record.pm >@@ -123,6 +123,16 @@ sub export { > Koha::Logger->get->info( $msg ); > next; > } >+ # The standard UNIMARC for bibliographic records requires than the >+ # 9th character (starting from 0) in labels must be blank, but it >+ # must keep the 'a' value in MARC21 and Koha needs it. Therefore, >+ # for UNIMARC bibliographic records, it is only corrected for export >+ my $leader = $record->leader(); >+ my $marcflavour = C4::Context->preference("marcflavour"); >+ if ( $marcflavour eq 'UNIMARC' and $record_type eq 'bibs' ) { >+ substr( $leader, 9, 1 ) = ' '; >+ $record->leader($leader); >+ } > print $record->as_usmarc(); > } > } elsif ( $format eq 'xml' ) { >-- >2.7.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 18153
:
60552
|
60553
|
62244
|
62245
|
63009
| 68532