Bug 8347 - Koha forces UNIMARC 100 field code language to 'fre'
Summary: Koha forces UNIMARC 100 field code language to 'fre'
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Cataloging (show other bugs)
Version: unspecified
Hardware: All All
: P1 - high enhancement (vote)
Assignee: Vitor Fernandes
QA Contact: Katrin Fischer
URL:
Keywords:
Depends on: 4368 8136
Blocks: 9453
  Show dependency treegraph
 
Reported: 2012-07-03 05:46 UTC by Frédéric Demians
Modified: 2014-05-26 21:04 UTC (History)
5 users (show)

See Also:
Change sponsored?: Sponsored
Patch complexity: Small patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:


Attachments
BUG 8347 - Koha forces UNIMARC 100 field code language to 'fre' (4.87 KB, patch)
2012-11-29 11:05 UTC, Vitor Fernandes
Details | Diff | Splinter Review
BUG 8347 - Koha forces UNIMARC 100 field code language to 'fre' (1.27 KB, patch)
2012-12-04 16:19 UTC, Vitor Fernandes
Details | Diff | Splinter Review
BUG - Koha forces UNIMARC 100 field code language to 'fre' (2.26 KB, patch)
2012-12-05 15:36 UTC, Vitor Fernandes
Details | Diff | Splinter Review
[PASSED QA] BUG 8347 - Koha forces UNIMARC 100 field code language to 'fre' (6.00 KB, patch)
2013-02-17 22:47 UTC, Katrin Fischer
Details | Diff | Splinter Review
[PASSED QA] BUG 8347 - Koha forces UNIMARC 100 field code language to 'fre' (1.34 KB, patch)
2013-02-17 22:47 UTC, Katrin Fischer
Details | Diff | Splinter Review
[PASSED QA] BUG 8347 - Koha forces UNIMARC 100 field code language to 'fre' (4.41 KB, patch)
2013-02-17 22:47 UTC, Katrin Fischer
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Frédéric Demians 2012-07-03 05:46:30 UTC
Reported on Koha mailing list:

  I can not change the UNIMARC 100 FIELD  Language of cataloging. I
  changed the default "fre" to "chi",   I saved it . But I find all  100
  FIELD  Language of cataloging  are "fre" again.

Take a look at C4/Biblio.pm module, line 3547:

  substr( $string, 22, 6, "frey50" );

Check also rebuild_zebra.pl fix_unimarc_100() function.
Comment 1 Vitor Fernandes 2012-11-28 10:10:49 UTC
This should be a system preference.
I've done a similar patch to authorities 100 field, where the default language was french to.
I can devellop a patch for this, where "frey50" should the default value of the system preference.

Cataloguing tab -> Record structure section

UNIMARCField100 = "frey50"

What you think about this?
Comment 2 Vitor Fernandes 2012-11-29 11:05:50 UTC Comment hidden (obsolete)
Comment 3 Vitor Fernandes 2012-12-04 16:19:49 UTC Comment hidden (obsolete)
Comment 4 Vitor Fernandes 2012-12-05 15:36:08 UTC Comment hidden (obsolete)
Comment 5 Rolando Isidoro 2013-01-23 10:22:43 UTC
Tested and working in version 3.8.5.
Comment 6 Katrin Fischer 2013-02-17 22:47:29 UTC
Created attachment 15483 [details] [review]
[PASSED QA] BUG 8347 - Koha forces UNIMARC 100 field code language to 'fre'

Added a new system preference to set the UNIMARC field 100 default language.
The default value for that system preference is 'fre'.
Changed Biblio.pm to use the system preference:

- if the language is bad filled in the preferences it uses 'fre' as default value
- only replaces the language when the field 100 is empty
- if the language is filled with the plugin only replaces the positions 25-28 to 'y50'

Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Comment 7 Katrin Fischer 2013-02-17 22:47:37 UTC
Created attachment 15484 [details] [review]
[PASSED QA] BUG 8347 - Koha forces UNIMARC 100 field code language to 'fre'

Forget to add the system preference to the template.

Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Comment 8 Katrin Fischer 2013-02-17 22:47:46 UTC
Created attachment 15485 [details] [review]
[PASSED QA] BUG 8347 - Koha forces UNIMARC 100 field code language to 'fre'

Changed Charset.pm to use defaultlanguage instead of 'fre'.

http://bugs.koha-community.org/show_bug.cgi?id=8347

Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Passes all tests and QA script.

1) Check system preference was added correctly:
   UNIMARCField100Language
2) Change code in preference to be not 'fre'.
3) Catalog a bibliographic record.
  - check plugin shows new value
  - check empty field is filled with new value from the plugin
  - check you can still edit it to be something else
Comment 9 Jared Camins-Esakov 2013-02-20 14:08:03 UTC
This patch has been pushed to master.
Comment 10 Chris Cormack 2013-02-21 05:47:50 UTC
This does not apply on 3.10.x please rebase and submit if you wish it on that branch.
Comment 11 Vitor Fernandes 2013-02-21 08:23:24 UTC
Chris,

For me it's fine to only appear in 3.12.