From 361e5f83e21fd94364e34af71e4a7fc64a03d2cb Mon Sep 17 00:00:00 2001 From: Magnus Enger Date: Mon, 15 Apr 2013 19:50:19 +0200 Subject: [PATCH] Bug 7055 - NORMARC: Fix 008 position 15-17 and 35-37 This patch does several things: - Set the default for 008/15-17 to "no " (yes, there is space at the end) - Link from 008/15-17 in the value builder to NORMARC country codes - Set the default for 008/35-37 to "nor" (by setting the DefaultLanguageField008 syspref) - Link from 008/35-37 in the value builder to NORMARC language codes - Fix a missing around field 35-37 To reproduce: - Run through the Web-installer in Norwegian and choose NORMARC as the MARC flavour - Go to Home > Cataloging > Add MARC record and add a new record - Click in the field for 008. The default should look like: 130415t xxu||||| |||| 00| 0 eng d ^^^ ^^^ - Reload the page and open the value builder for 008. Problems: - The text for 15-17 links to MARC21 country codes - The default for 15-17 is xxu - The text for 35-37 links to MARC21 language codes - The default for 35-37 is eng - If you choose e.g. "Monografier" in the top dropdown then click on "OK" the window does not close To test: - Apply the patch and run through the Web-installer again, selecting Norwegian and NORMARC - Go to Home > Cataloging > Add MARC record and add a new record - Click in the field for 008. The default should look like: 130415t no ||||| |||| 00| 0 nor d ^^^ ^^^ - Reload the page and open the value builder for 008. - Check that... - The default for 15-17 is "no " (with a space at the end) - The link goes to NORMARC country codes - The default for 35-37 is "nor" - The link goes to NORMARC language codes - Select something from the top dropdown and click "OK". Check that the window closes and that the values that are entered into the 008 field matches what you chose in the popup window. Signed-off-by: Chris Cormack Trusing Magnus is right, so testing for any regressions mainly, all good Signed-off-by: Katrin Fischer Only changes NORMARC specific plugin and system preferences files. Changes all seem logical to me. Signed-off-by: Jared Camins-Esakov --- cataloguing/value_builder/normarc_field_008.pl | 4 ++-- .../data/mysql/nb-NO/1-Obligatorisk/system_preferences.sql | 1 + .../modules/cataloguing/value_builder/normarc_field_008.tt | 7 ++++--- 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/cataloguing/value_builder/normarc_field_008.pl b/cataloguing/value_builder/normarc_field_008.pl index 5efe9a8ee7..98ca163273 100755 --- a/cataloguing/value_builder/normarc_field_008.pl +++ b/cataloguing/value_builder/normarc_field_008.pl @@ -58,7 +58,7 @@ function Focus$function_name(subfield_managed) { if ( document.getElementById(\"$field_number\").value ) { } else { - document.getElementById(\"$field_number\").value='$dateentered' + 't xxu||||| |||| 00| 0 $lang d'; + document.getElementById(\"$field_number\").value='$dateentered' + 't no ||||| |||| 00| 0 $lang d'; } return 1; } @@ -101,7 +101,7 @@ sub plugin { ); # $result = " t xxu 00 0 eng d" unless $result; - $result = "$dateentered" . "t xxu||||| |||| 00| 0 $lang d" unless $result; + $result = "$dateentered" . "t no ||||| |||| 00| 0 $lang d" unless $result; my $f1 = substr($result, 0, 6); my $f6 = substr($result, 6, 1); my $f710 = substr($result, 7, 4); diff --git a/installer/data/mysql/nb-NO/1-Obligatorisk/system_preferences.sql b/installer/data/mysql/nb-NO/1-Obligatorisk/system_preferences.sql index c60594433a..eeedc86367 100644 --- a/installer/data/mysql/nb-NO/1-Obligatorisk/system_preferences.sql +++ b/installer/data/mysql/nb-NO/1-Obligatorisk/system_preferences.sql @@ -28,3 +28,4 @@ UPDATE systempreferences SET value = '

Viktige lenker kan plasseres her

' W UPDATE systempreferences SET value = '
  • Andre bibliotek (WorldCat)
  • Andre databaser (Google Scholar)
  • Nettbutikker (Bookfinder.com)
  • ' WHERE variable = 'OPACSearchForTitleIn'; UPDATE systempreferences SET value = 'Monday' WHERE variable = 'CalendarFirstDayOfWeek'; UPDATE systempreferences SET value = 'A B C D E F G H I J K L M N O P Q R S T U V W X Y Z Æ Ø Å' WHERE variable = 'alphabet'; +UPDATE systempreferences SET value = 'nor' WHERE variable = 'DefaultLanguageField008'; diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/normarc_field_008.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/normarc_field_008.tt index cfdba9c5c2..14101b1f0e 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/normarc_field_008.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/normarc_field_008.tt @@ -128,9 +128,9 @@ - See MARC Code List for Countries + (Se NORMARC-koder for land) - + @@ -139,7 +139,8 @@ - See MARC Code List for Languages + + (Se NORMARC-koder for sprÃ¥k) -- 2.39.5