From 0837c9cab481ccd792236e6f98e866e9260a7d41 Mon Sep 17 00:00:00 2001 From: Salvador Zaragoza Rubio Date: Wed, 23 Feb 2011 17:37:07 +0100 Subject: [PATCH] Bug 3013 - 006/008 Type of Material Display on cataloguing plugin for MARC21 Content-Type: text/plain; charset="utf-8" Modification of the intranet cataloguing plugin for 006/008 fields to allow select a type of material and change the positions available to enter the data. Data are hard stored in xml files to allow easy translation and processing through Javascript and AJAX. Follow-up fix for Bug 3013 - 006/008 Type of Material Display on cataloguing plugin for MARC21 Add url functionality in the xml and updatedatabase Signed-off-by: Salvador Zaragoza Rubio --- cataloguing/value_builder/marc21_field_006.pl | 107 +- cataloguing/value_builder/marc21_field_008.pl | 141 ++- installer/data/mysql/de-DE/mandatory/sysprefs.sql | 1 + installer/data/mysql/en/mandatory/sysprefs.sql | 1 + .../1-Obligatoire/unimarc_standard_systemprefs.sql | 2 + installer/data/mysql/it-IT/necessari/sysprefs.sql | 1 + installer/data/mysql/pl-PL/mandatory/sysprefs.sql | 1 + ...m_preferences_full_optimal_for_install_only.sql | 1 + ...m_preferences_full_optimal_for_install_only.sql | 1 + installer/data/mysql/updatedatabase.pl | 8 + .../intranet-tmpl/prog/en/js/xmlControlfield.js | 341 +++++ .../en/modules/admin/preferences/cataloguing.pref | 6 + .../value_builder/marc21_field_006.tmpl | 157 ++- .../cataloguing/value_builder/marc21_field_006.xml | 795 ++++++++++++ .../value_builder/marc21_field_008.tmpl | 533 +++++---- .../cataloguing/value_builder/marc21_field_008.xml | 1298 ++++++++++++++++++++ .../cataloguing/value_builder/marc21_field_CF.xsd | 83 ++ 17 files changed, 3097 insertions(+), 380 deletions(-) mode change 100644 => 100755 installer/data/mysql/de-DE/mandatory/sysprefs.sql mode change 100644 => 100755 installer/data/mysql/en/mandatory/sysprefs.sql mode change 100644 => 100755 installer/data/mysql/fr-FR/1-Obligatoire/unimarc_standard_systemprefs.sql mode change 100644 => 100755 installer/data/mysql/it-IT/necessari/sysprefs.sql mode change 100644 => 100755 installer/data/mysql/pl-PL/mandatory/sysprefs.sql mode change 100644 => 100755 installer/data/mysql/ru-RU/mandatory/system_preferences_full_optimal_for_install_only.sql mode change 100644 => 100755 installer/data/mysql/uk-UA/mandatory/system_preferences_full_optimal_for_install_only.sql create mode 100755 koha-tmpl/intranet-tmpl/prog/en/js/xmlControlfield.js mode change 100644 => 100755 koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/cataloguing.pref mode change 100644 => 100755 koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_006.tmpl create mode 100755 koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_006.xml mode change 100644 => 100755 koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_008.tmpl create mode 100755 koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_008.xml create mode 100755 koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_CF.xsd mode change 100644 => 100755 kohaversion.pl diff --git a/cataloguing/value_builder/marc21_field_006.pl b/cataloguing/value_builder/marc21_field_006.pl index 6d84cb4..5f40e89 100755 --- a/cataloguing/value_builder/marc21_field_006.pl +++ b/cataloguing/value_builder/marc21_field_006.pl @@ -26,6 +26,8 @@ use C4::Context; use C4::Search; use C4::Output; +use XML::LibXML; + =head1 DESCRIPTION plugin_parameters : other parameters added when the plugin is called by the dopop function @@ -82,46 +84,71 @@ sub plugin { ); $result = "a|||||r|||| 00| 0 " unless $result; - # $result = "a r 00 0 " unless $result; - my $f0 = substr($result, 0, 1); - my $f014 = substr($result, 1, 4); - my $f5 = substr($result, 5, 1); - my $f6 = substr($result, 6, 1); - my $f710 = substr($result, 7, 4); - my $f11 = substr($result, 11, 1); - my $f12 = substr($result, 12, 1); - my $f13 = substr($result, 13, 1); - my $f14 = substr($result, 14, 1); - my $f15 = substr($result, 15, 1); - my $f16 = substr($result, 16, 1); - my $f17 = substr($result, 17, 1); - - $template->param( - index => $index, - f0 => $f0, - "f0$f0" => $f0, - f014 => $f014, - "f014$f014" => $f014, - f5 => $f5, - "f5$f5" => $f5, - f6 => $f6, - "f6$f6" => $f6, - f710 => $f710, - "f710$f710" => $f710, - f11 => $f11, - "f11$f11" => $f11, - f12 => $f12, - "f12$f12" => $f12, - f13 => $f13, - "f13$f13" => $f13, - f14 => $f14, - "f14$f14" => $f14, - f15 => $f15, - "f15$f15" => $f15, - f16 => $f16, - "f16$f16" => $f16, - f17 => $f17, - "f17$f17" => $f17, + # Check whether we want to use Type of Material display with xml + my $viewMaterialTypesMode = C4::Context->preference("TypeOfMaterialsView_006_008"); + # Check if the xml, xsd exists and is validated + if ($viewMaterialTypesMode) { + my $dir = C4::Context->config('intrahtdocs') . '/prog/' . $template->param('lang') . '/modules/cataloguing/value_builder/'; + if (-r $dir . 'marc21_field_006.xml') { + my $doc = XML::LibXML->new->parse_file($dir . 'marc21_field_006.xml'); + if (-r $dir . 'marc21_field_CF.xsd') { + my $xmlschema = XML::LibXML::Schema->new(location => $dir . 'marc21_field_CF.xsd'); + eval { + $xmlschema->validate( $doc ); + }; + $viewMaterialTypesMode = 0 if ($@); + } + } else { + $viewMaterialTypesMode = 0; + } + } + unless ($viewMaterialTypesMode) { + # $result = "a r 00 0 " unless $result; + my $f0 = substr($result, 0, 1); + my $f014 = substr($result, 1, 4); + my $f5 = substr($result, 5, 1); + my $f6 = substr($result, 6, 1); + my $f710 = substr($result, 7, 4); + my $f11 = substr($result, 11, 1); + my $f12 = substr($result, 12, 1); + my $f13 = substr($result, 13, 1); + my $f14 = substr($result, 14, 1); + my $f15 = substr($result, 15, 1); + my $f16 = substr($result, 16, 1); + my $f17 = substr($result, 17, 1); + + $template->param( + f0 => $f0, + "f0$f0" => $f0, + f014 => $f014, + "f014$f014" => $f014, + f5 => $f5, + "f5$f5" => $f5, + f6 => $f6, + "f6$f6" => $f6, + f710 => $f710, + "f710$f710" => $f710, + f11 => $f11, + "f11$f11" => $f11, + f12 => $f12, + "f12$f12" => $f12, + f13 => $f13, + "f13$f13" => $f13, + f14 => $f14, + "f14$f14" => $f14, + f15 => $f15, + "f15$f15" => $f15, + f16 => $f16, + "f16$f16" => $f16, + f17 => $f17, + "f17$f17" => $f17, + ); + } else { + $template->param(tagfield => '006'); + } + $template->param(index => $index, + result => $result, + viewMaterialTypesMode => $viewMaterialTypesMode, ); output_html_with_http_headers $input, $cookie, $template->output; } diff --git a/cataloguing/value_builder/marc21_field_008.pl b/cataloguing/value_builder/marc21_field_008.pl index 57e0690..c63cda5 100755 --- a/cataloguing/value_builder/marc21_field_008.pl +++ b/cataloguing/value_builder/marc21_field_008.pl @@ -26,6 +26,8 @@ use C4::Context; use C4::Search; use C4::Output; +use XML::LibXML; + =head1 DESCRIPTION plugin_parameters : other parameters added when the plugin is called by the dopop function @@ -96,65 +98,90 @@ sub plugin { # $result = " t xxu 00 0 eng d" unless $result; $result = "$dateentered" . "t xxu||||| |||| 00| 0 eng d" unless $result; - my $f1 = substr($result, 0, 6); - my $f6 = substr($result, 6, 1); - my $f710 = substr($result, 7, 4); - my $f1114 = substr($result, 11, 4); - my $f1517 = substr($result, 15, 3); - my $f1821 = substr($result, 18, 4); - my $f22 = substr($result, 22, 1); - my $f23 = substr($result, 23, 1); - my $f2427 = substr($result, 24, 4); - my $f28 = substr($result, 28, 1); - my $f29 = substr($result, 29, 1); - my $f30 = substr($result, 30, 1); - my $f31 = substr($result, 31, 1); - my $f33 = substr($result, 33, 1); - my $f34 = substr($result, 34, 1); - my $f3537 = substr($result, 35, 3); - my $f38 = substr($result, 38, 1); - my $f39 = substr($result, 39, 1); - - # bug 2563 - $f710 = "" if ($f710 =~ /^\s*$/); - $f1114 = "" if ($f1114 =~ /^\s*$/); - - if ((!$f1) || ($f1 =~ m/ /)) { - $f1 = $dateentered; + # Check whether we want to use Type of Material display with xml + my $viewMaterialTypesMode = C4::Context->preference("TypeOfMaterialsView_006_008"); + # Check if the xml, xsd exists and is validated + if ($viewMaterialTypesMode) { + my $dir = C4::Context->config('intrahtdocs') . '/prog/' . $template->param('lang') . '/modules/cataloguing/value_builder/'; + if (-r $dir . 'marc21_field_008.xml') { + my $doc = XML::LibXML->new->parse_file($dir . 'marc21_field_008.xml'); + if (-r $dir . 'marc21_field_CF.xsd') { + my $xmlschema = XML::LibXML::Schema->new(location => $dir . 'marc21_field_CF.xsd'); + eval { + $xmlschema->validate( $doc ); + }; + $viewMaterialTypesMode = 0 if ($@); + } + } else { + $viewMaterialTypesMode = 0; + } } + unless ($viewMaterialTypesMode) { + my $f1 = substr($result, 0, 6); + my $f6 = substr($result, 6, 1); + my $f710 = substr($result, 7, 4); + my $f1114 = substr($result, 11, 4); + my $f1517 = substr($result, 15, 3); + my $f1821 = substr($result, 18, 4); + my $f22 = substr($result, 22, 1); + my $f23 = substr($result, 23, 1); + my $f2427 = substr($result, 24, 4); + my $f28 = substr($result, 28, 1); + my $f29 = substr($result, 29, 1); + my $f30 = substr($result, 30, 1); + my $f31 = substr($result, 31, 1); + my $f33 = substr($result, 33, 1); + my $f34 = substr($result, 34, 1); + my $f3537 = substr($result, 35, 3); + my $f38 = substr($result, 38, 1); + my $f39 = substr($result, 39, 1); + + # bug 2563 + $f710 = "" if ($f710 =~ /^\s*$/); + $f1114 = "" if ($f1114 =~ /^\s*$/); + + if ((!$f1) || ($f1 =~ m/ /)) { + $f1 = $dateentered; + } - $template->param( - index => $index, - f1 => $f1, - f6 => $f6, - "f6$f6" => $f6, - f710 => $f710, - f1114 => $f1114, - f1517 => $f1517, - f1821 => $f1821, - f22 => $f22, - "f22$f22" => $f22, - f23 => $f23, - "f23$f23" => $f23, - f2427 => $f2427, - "f24$f2427" => $f2427, - f28 => $f28, - "f28$f28" => $f28, - f29 => $f29, - "f29$f29" => $f29, - f30 => $f30, - "f30$f30" => $f30, - f31 => $f31, - "f31$f31" => $f31, - f33 => $f33, - "f33$f33" => $f33, - f34 => $f34, - "f34$f34" => $f34, - f3537 => $f3537, - f38 => $f38, - "f38$f38" => $f38, - f39 => $f39, - "f39$f39" => $f39, + $template->param( + f1 => $f1, + f6 => $f6, + "f6$f6" => $f6, + f710 => $f710, + f1114 => $f1114, + f1517 => $f1517, + f1821 => $f1821, + f22 => $f22, + "f22$f22" => $f22, + f23 => $f23, + "f23$f23" => $f23, + f2427 => $f2427, + "f24$f2427" => $f2427, + f28 => $f28, + "f28$f28" => $f28, + f29 => $f29, + "f29$f29" => $f29, + f30 => $f30, + "f30$f30" => $f30, + f31 => $f31, + "f31$f31" => $f31, + f33 => $f33, + "f33$f33" => $f33, + f34 => $f34, + "f34$f34" => $f34, + f3537 => $f3537, + f38 => $f38, + "f38$f38" => $f38, + f39 => $f39, + "f39$f39" => $f39, + ); + } else { + $template->param(tagfield => '008'); + } + $template->param(index => $index, + result => $result, + viewMaterialTypesMode => $viewMaterialTypesMode, ); output_html_with_http_headers $input, $cookie, $template->output; } diff --git a/installer/data/mysql/de-DE/mandatory/sysprefs.sql b/installer/data/mysql/de-DE/mandatory/sysprefs.sql old mode 100644 new mode 100755 index 221017a..eb7184a --- a/installer/data/mysql/de-DE/mandatory/sysprefs.sql +++ b/installer/data/mysql/de-DE/mandatory/sysprefs.sql @@ -287,3 +287,4 @@ INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ( INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ('ShelfBrowserUsesCcode','1','Use the item collection code when finding items for the shelf browser.','0','YesNo'); INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('AllowFineOverride','0','If on, staff will be able to issue books to patrons with fines greater than noissuescharge.','0','YesNo'); INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('AllFinesNeedOverride','1','If on, staff will be asked to override every fine, even if it is below noissuescharge.','0','YesNo'); +INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('TypeOfMaterialsView_006_008','0','Display Type of Materials for plugin of fields 006 and 008 when cataloguing','','YesNo'); diff --git a/installer/data/mysql/en/mandatory/sysprefs.sql b/installer/data/mysql/en/mandatory/sysprefs.sql old mode 100644 new mode 100755 index 363774d..514ea94 --- a/installer/data/mysql/en/mandatory/sysprefs.sql +++ b/installer/data/mysql/en/mandatory/sysprefs.sql @@ -287,3 +287,4 @@ INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('ShelfBrowserUsesCcode','1','Use the item collection code when finding items for the shelf browser.','0','YesNo'); INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('AllowFineOverride','0','If on, staff will be able to issue books to patrons with fines greater than noissuescharge.','0','YesNo'); INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('AllFinesNeedOverride','1','If on, staff will be asked to override every fine, even if it is below noissuescharge.','0','YesNo'); +INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('TypeOfMaterialsView_006_008','0','Display Type of Materials for plugin of fields 006 and 008 when cataloguing','','YesNo'); diff --git a/installer/data/mysql/fr-FR/1-Obligatoire/unimarc_standard_systemprefs.sql b/installer/data/mysql/fr-FR/1-Obligatoire/unimarc_standard_systemprefs.sql old mode 100644 new mode 100755 index 9386fee..7a1d90e --- a/installer/data/mysql/fr-FR/1-Obligatoire/unimarc_standard_systemprefs.sql +++ b/installer/data/mysql/fr-FR/1-Obligatoire/unimarc_standard_systemprefs.sql @@ -287,5 +287,7 @@ INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES(' INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('ShelfBrowserUsesLocation','1','Use the item location when finding items for the shelf browser.','1','YesNo'); INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ('ShelfBrowserUsesHomeBranch','1','Use the item home branch when finding items for the shelf browser.','1','YesNo'); INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ('ShelfBrowserUsesCcode','1','Use the item collection code when finding items for the shelf browser.','0','YesNo'); +<<<<<<< HEAD:installer/data/mysql/fr-FR/1-Obligatoire/unimarc_standard_systemprefs.sql INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('AllowFineOverride','0','If on, staff will be able to issue books to patrons with fines greater than noissuescharge.','0','YesNo'); INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('AllFinesNeedOverride','1','If on, staff will be asked to override every fine, even if it is below noissuescharge.','0','YesNo'); +INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('TypeOfMaterialsView_006_008','0','Display Type of Materials for plugin of fields 006 and 008 when cataloguing','','YesNo'); diff --git a/installer/data/mysql/it-IT/necessari/sysprefs.sql b/installer/data/mysql/it-IT/necessari/sysprefs.sql old mode 100644 new mode 100755 index 49da6ce..53f4e64 --- a/installer/data/mysql/it-IT/necessari/sysprefs.sql +++ b/installer/data/mysql/it-IT/necessari/sysprefs.sql @@ -274,3 +274,4 @@ INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ( INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ('ShelfBrowserUsesCcode','1','Use the item collection code when finding items for the shelf browser.','0','YesNo'); INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('AllowFineOverride','0','If on, staff will be able to issue books to patrons with fines greater than noissuescharge.','0','YesNo'); INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('AllFinesNeedOverride','1','If on, staff will be asked to override every fine, even if it is below noissuescharge.','0','YesNo'); +INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('TypeOfMaterialsView_006_008','0','Display Type of Materials for plugin of fields 006 and 008 when cataloguing','','YesNo'); diff --git a/installer/data/mysql/pl-PL/mandatory/sysprefs.sql b/installer/data/mysql/pl-PL/mandatory/sysprefs.sql old mode 100644 new mode 100755 index 5715de1..0867b83 --- a/installer/data/mysql/pl-PL/mandatory/sysprefs.sql +++ b/installer/data/mysql/pl-PL/mandatory/sysprefs.sql @@ -286,3 +286,4 @@ INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ( INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ('ShelfBrowserUsesCcode','1','Use the item collection code when finding items for the shelf browser.','0','YesNo'); INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('AllowFineOverride','0','If on, staff will be able to issue books to patrons with fines greater than noissuescharge.','0','YesNo'); INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('AllFinesNeedOverride','1','If on, staff will be asked to override every fine, even if it is below noissuescharge.','0','YesNo'); +INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('TypeOfMaterialsView_006_008','0','Display Type of Materials for plugin of fields 006 and 008 when cataloguing','','YesNo'); diff --git a/installer/data/mysql/ru-RU/mandatory/system_preferences_full_optimal_for_install_only.sql b/installer/data/mysql/ru-RU/mandatory/system_preferences_full_optimal_for_install_only.sql old mode 100644 new mode 100755 index 2b38cfa..1f06a1d --- a/installer/data/mysql/ru-RU/mandatory/system_preferences_full_optimal_for_install_only.sql +++ b/installer/data/mysql/ru-RU/mandatory/system_preferences_full_optimal_for_install_only.sql @@ -341,3 +341,4 @@ INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ( INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ('ShelfBrowserUsesCcode','1','Use the item collection code when finding items for the shelf browser.','0','YesNo'); INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('AllowFineOverride','0','If on, staff will be able to issue books to patrons with fines greater than noissuescharge.','0','YesNo'); INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('AllFinesNeedOverride','1','If on, staff will be asked to override every fine, even if it is below noissuescharge.','0','YesNo'); +INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('TypeOfMaterialsView_006_008','0','Display Type of Materials for plugin of fields 006 and 008 when cataloguing','','YesNo'); diff --git a/installer/data/mysql/uk-UA/mandatory/system_preferences_full_optimal_for_install_only.sql b/installer/data/mysql/uk-UA/mandatory/system_preferences_full_optimal_for_install_only.sql old mode 100644 new mode 100755 index 874a6e4..33e0073 --- a/installer/data/mysql/uk-UA/mandatory/system_preferences_full_optimal_for_install_only.sql +++ b/installer/data/mysql/uk-UA/mandatory/system_preferences_full_optimal_for_install_only.sql @@ -366,3 +366,4 @@ INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ( INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ('ShelfBrowserUsesCcode','1','Use the item collection code when finding items for the shelf browser.','0','YesNo'); INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('AllowFineOverride','0','If on, staff will be able to issue books to patrons with fines greater than noissuescharge.','0','YesNo'); INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('AllFinesNeedOverride','1','If on, staff will be asked to override every fine, even if it is below noissuescharge.','0','YesNo'); +INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('TypeOfMaterialsView_006_008','0','Display Type of Materials for plugin of fields 006 and 008 when cataloguing','','YesNo'); diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl index b4c51c0..b784c3d 100755 --- a/installer/data/mysql/updatedatabase.pl +++ b/installer/data/mysql/updatedatabase.pl @@ -4022,6 +4022,14 @@ if (C4::Context->preference("Version") < TransformToNum($DBversion)) { SetVersion($DBversion); }; +$DBversion = '3.03.00.XXX'; #FIXME +if (C4::Context->preference("Version") < TransformToNum($DBversion)) { + # 006/008 plugins show Type of Materials and change fields form to view the allowed values for the different positions + $dbh->do("INSERT INTO `systempreferences` (variable,value,explanation,options,type) VALUES ('TypeOfMaterialsView_006_008','0','Display Type of Materials for plugin of fields 006 and 008 when cataloguing','','YesNo')"); + print "Upgrade to $DBversion done (006/008 plugins show Type of Materials positions selection)\n"; + SetVersion($DBversion); +} + =head1 FUNCTIONS =head2 DropAllForeignKeys($table) diff --git a/koha-tmpl/intranet-tmpl/prog/en/js/xmlControlfield.js b/koha-tmpl/intranet-tmpl/prog/en/js/xmlControlfield.js new file mode 100755 index 0000000..67b0bf5 --- /dev/null +++ b/koha-tmpl/intranet-tmpl/prog/en/js/xmlControlfield.js @@ -0,0 +1,341 @@ + + +// Add an option to a select form field +function add_option(select, text, value, selected) +{ + var option = document.createElement('option'); + option.text = text; + option.value = value; + if (selected) option.selected = true; + try { + select.add(option, null); + } + catch(ex) { + select.add(option); + } +}//add_option + + +// Return the value of a parameter from the url +function returnValueParam(param) +{ + var params = location.search.substr(1); + var arr = params.split("&"); + var pattern = param + "="; + for (var i=0; i < arr.length; i++) { + if (arr[i].indexOf(pattern) == 0) { + return unescape(arr[i].substr(pattern.length)); + } + } + return ""; +}//returnValueParam + + +// Return a value from a position on the result string +function returnValuePosFromResult(result, pos) +{ + var index; + if ((index = pos.indexOf("-")) > 0) { + var ini = parseInt(pos.substring(0, index) ,10); + var end = parseInt(pos.substr(index + 1) ,10); + return result.substring(ini, end + 1); + } else { + return result.substr(pos, 1); + } +}//returnValuePosFromResult + + +// Build string from form fields +function returnResultFromValues(form) +{ + var resultStr = form.result.value; + var pos; + var value; + for (var i=0; i < form.elements.length; i++) { + var pattern = new RegExp("f[0-9]+(?:[0-9]+)?"); + if (pattern.test(form.elements[i].name)) { + pos = form.elements[i].name.substr(1); + value = (pos.indexOf("-") > 0)?form.elements[i].value:form.elements[i].options[form.elements[i].selectedIndex].value; + resultStr = changePosResult(pos, value, resultStr); + } + } + return resultStr; +}//returnResultFromValues + + +// Build/modify result string for a position and a value +function changePosResult(pos, value, resultStr) +{ + var index; + var result = ""; + if ((index = pos.indexOf("-")) > 0) { + var ini = parseInt(pos.substring(0, index) ,10); + var end = parseInt(pos.substr(index + 1) ,10); + var roffset = (1 + end - ini)- value.length; + if (roffset > 0) for (var i=0; i < roffset; i++) value += " "; + if (ini == 0) + result = value + resultStr.substr(end + 1); + else { + result = resultStr.substring(0, ini) + value; + if (end < resultStr.length) + result += resultStr.substr(end + 1); + } + } else { + var ini = parseInt(pos, 10); + if (ini == 0) + result = value + resultStr.substr(1); + else { + result = resultStr.substring(0, ini) + value; + if (ini < resultStr.length) + result += resultStr.substr(ini + 1); + } + } + result = result.replace(/#/g, " "); + return result; +}//changePosResult + + +// Display the result string on a table indicating positions and coloring them if wrong or selected +function renderResult(tr_result, result) +{ + if (tr_result) { + var td; + if (tr_result.cells.length != result.length) { + for (var i = tr_result.cells.length - 1; i >= 0; i--) + tr_result.deleteCell(i); + for (var i=0; i < result.length; i++) { + value = result.charAt(i); + td = tr_result.insertCell(tr_result.cells.length); + } + } + var value; + var ini = -1; + var end = -1; + var args = renderResult.arguments; + if (args.length > 2) { + var index; + if ((index = args[2].indexOf("-")) > 0) { + ini = parseInt(args[2].substring(0, index) ,10); + end = parseInt(args[2].substr(index + 1) ,10); + } else ini = parseInt(args[2], 10); + } + for (var i=0; i < result.length; i++) { + value = result.charAt(i); + td = tr_result.cells[i]; + if (td.style.backgroundColor != "yellow") td.style.backgroundColor = "white"; + td.innerHTML = (value == " ")?" ":value; + td.title = "Pos " + i + ". Value: \"" + value + "\""; + if (ini >= 0) { + if (end > 0) { + if (ini <= i && i <= end) td.style.backgroundColor = "#cccccc"; + } else if (i == ini) td.style.backgroundColor = "#cccccc"; + } else { + var pos = (i < 10)?'0' + i:i + ''; + var obj; + if ((obj = document.getElementById('f' + pos)) != null) { + var found = false; + for (var j=0; j < obj.options.length && !found; j++) + if (obj.options[j].value == value) found = true; + if (!found) { + td.style.backgroundColor = "yellow"; + td.title = "Pos " + i + ". Bad Value: \"" + value + "\""; + } + } + } + }//for + } +}//renderResult + + +// Change displaying of result in the page +function changeH4Result(form, h4_result, tr_result, pos, value) +{ + var resultStr = form.result.value; + var result = changePosResult(pos, value, resultStr); + renderResult(tr_result, result, pos); + h4_result.innerHTML = result; + form.result.value = result; +}//changeH4Result + + + +// Class to read the xml and render the type of material +(function() +{ + + xmlControlField = function(tagfield, form_id, select, table, h4_result, tr_result, idMaterial) + { + this.tagfield = tagfield; + this.idMaterial = idMaterial; + this.form_id = form_id; + this.form = document.getElementById(form_id); + this.select = select; + this.table = table; + this.h4_result = h4_result; + this.tr_result = tr_result; + };//xmlControlField + + + xmlControlField.prototype = + { + tagfield: "", + idMaterial: "", + root: null, + form_id: "", + form: null, + select: null, + table: null, + h4_result: "", + tr_result: "", + + + setIdMaterial: function(idMaterial) + { + this.idMaterial = idMaterial; + },//setIdMaterial + + loadXmlValues: function() + { + var xmlhttp; + try { + if (window.XMLHttpRequest) { + xmlhttp = new XMLHttpRequest(); + if (xmlhttp.overrideMimeType) { + xmlhttp.overrideMimeType('text/xml'); + } + } else if (window.ActiveXObject) { + xmlhttp = new ActiveXObject("Microsoft.XMLHTTP") || new ActiveXObject("Msxml2.XMLHTTP"); + } + xmlhttp.open("GET", "/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_" + this.tagfield + ".xml", false); + xmlhttp.send(null); + this.xmlDoc = xmlhttp.responseXML; + if (this.xmlDoc) this.renderTemplate(); + } catch (e) { + //alert(e); + } + },//loadXmlValues + + + renderTemplate: function() + { + this.root = this.xmlDoc.documentElement; + if (this.root.nodeName == "Tagfield" && this.root.nodeType == 1 && this.root.hasChildNodes()) { + var tag = this.root.attributes.getNamedItem("tag").nodeValue; + var nodeMaterial = this.root.getElementsByTagName('Material'); + if (nodeMaterial != null && nodeMaterial.length > 0) { + if (this.idMaterial == "") this.idMaterial = nodeMaterial[0].attributes.getNamedItem("id").nodeValue; + this.renderSelectMaterial(nodeMaterial); + this.renderPositions(nodeMaterial, (this.form.result.value != "")?this.form.result.value:returnValueParam("result")); + } + } + },//renderTemplate + + + renderSelectMaterial: function(nodeMaterial) + { + if (this.select != null && nodeMaterial != null && nodeMaterial.length > 0) { + if (this.select.options.length <= 1) { + var id; + var name; + var arrSort = new Array(); + var arrEquiv = new Array(); + for (var i=0; i < nodeMaterial.length; i++) { + id = nodeMaterial[i].attributes.getNamedItem("id").nodeValue; + name = nodeMaterial[i].attributes.getNamedItem("name").nodeValue; + arrEquiv[id] = i; + arrSort.push(id); + } + arrSort.sort(); + var j; + for (var i=0; i < arrSort.length; i++) { + j = arrEquiv[arrSort[i]]; + add_option(this.select, arrSort[i] + " - " + nodeMaterial[j].attributes.getNamedItem("name").nodeValue, arrSort[i], (this.idMaterial != "" && arrSort[i] == this.idMaterial)?true:false); + } + } else if (this.idMaterial != "") { + for (var i=0; i < this.select.options.length; i++) { + if (this.select.options[i].value == this.idMaterial) this.select.options[i].selected = true; + } + } + } + },//renderSelectMaterial + + + renderPositions: function(nodeMaterial, result) + { + var materialNode; + try { + var resultXPath = this.xmlDoc.evaluate("//a:Material[@id='" + this.idMaterial + "']", this.xmlDoc.documentElement, null, XPathResult.FIRST_ORDERED_NODE_TYPE, null); + materialNode = resultXPath.singleNodeValue; + } catch (e) { + for (var i=0; i < nodeMaterial.length; i++) { + if (this.idMaterial == nodeMaterial[i].attributes.getNamedItem("id").nodeValue) { + materialNode = nodeMaterial[i]; + break; + } + } + } + if (this.table != null) { + var tbody = this.table.tBodies[0]; + if (tbody.rows.length > 0) + for (var i = tbody.rows.length - 1; i >= 1; i--) + tbody.deleteRow(i); + if (materialNode != undefined && materialNode != null && materialNode.nodeType == 1 && materialNode.hasChildNodes()) { + var nodePos = materialNode.firstChild; + var tr; + var td; + var title; + var pos; + var value; + var strInnerHTML = ""; + var selected; + var index; + var url; + while (nodePos != null) { + if (nodePos.nodeType == 1 && nodePos.nodeName == "Position") { + tr = tbody.insertRow(tbody.rows.length); + td = tr.insertCell(tr.cells.length); + pos = nodePos.attributes.getNamedItem("pos").nodeValue; + title = ((nodePos.getAttributeNode("description") || nodePos.hasAttribute("description")) && nodePos.getAttribute("description") != "")?nodePos.attributes.getNamedItem("description").nodeValue:nodePos.attributes.getNamedItem("name").nodeValue; + try { + url = ((nodePos.getAttributeNode("url") || nodePos.hasAttribute("url")) && nodePos.getAttribute("url") != "" && nodePos.getAttribute("urltext") != "")?" " + nodePos.attributes.getNamedItem("urltext").nodeValue + "":""; + } catch (e) { url = "";} + td.innerHTML = ""; + td = tr.insertCell(tr.cells.length); + value = returnValuePosFromResult(result, pos); + if ((index = pos.indexOf("-")) > 0) { + var ini = parseInt(pos.substring(0, index) ,10); + var end = parseInt(pos.substr(index + 1) ,10); + value = value.replace(/ /g, "#"); + strInnerHTML = ""; + } else { + strInnerHTML = ""; + } + //alert(strInnerHTML); + td.innerHTML = strInnerHTML; + } + nodePos = nodePos.nextSibling; + } + } + } + }//renderPositions + }; + +})(); + diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/cataloguing.pref b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/cataloguing.pref old mode 100644 new mode 100755 index d809022..0c3bd46 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/cataloguing.pref +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/cataloguing.pref @@ -118,4 +118,10 @@ Cataloging: yes: Hide no: "Don't hide" - items marked as suppressed from OPAC search results. Note that you must have the Suppress index set up in Zebra and at least one suppressed item, or your searches will be broken. + - + - pref: TypeOfMaterialsView_006_008 + choices: + yes: "Don't hide" + no: Hide + - 006/008 plugins show Type of Materials and change fields form to view the allowed values for the different positions. diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_006.tmpl b/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_006.tmpl old mode 100644 new mode 100755 index ab2a079..7240639 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_006.tmpl +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_006.tmpl @@ -1,14 +1,67 @@ Koha › Cataloging › 006 builder + + + + + + - +onload="loadXmlValues()">

006 Fixed-length data elements--Additional material characteristics--General information

-
+ + + + + +
+

+ + + - - - + +" /> +
+ + + + + + + + - - + + + - + - + - - + + + + - - - - + + + + - + +
+ +
-
01-04 Illustrations (auto-filled from 300)"/>
@@ -119,7 +172,7 @@ - + @@ -175,7 +228,7 @@
@@ -246,7 +299,7 @@ -
15 Undefined
15 Undefined
Cancel
@@ -510,24 +564,27 @@ function report() { var doc = opener.document; var field = doc.getElementById(""); - + + field.value = document.getElementById("h4_result").innerHTML; + field.value = - ''+ - document.f_pop.f0.value+ - document.f_pop.f014.value+ - document.f_pop.f5.value+ - document.f_pop.f6.value+ - document.f_pop.f710.value+ - document.f_pop.f11.value+ - document.f_pop.f12.value+ - document.f_pop.f13.value+ - document.f_pop.f14.value+ ' '+ - document.f_pop.f16.value+ - document.f_pop.f17.value; - self.close(); - return false; - } - //]]> + ''+ + document.f_pop.f0.value+ + document.f_pop.f014.value+ + document.f_pop.f5.value+ + document.f_pop.f6.value+ + document.f_pop.f710.value+ + document.f_pop.f11.value+ + document.f_pop.f12.value+ + document.f_pop.f13.value+ + document.f_pop.f14.value+ ' '+ + document.f_pop.f16.value+ + document.f_pop.f17.value; + + self.close(); + return false; + } + //]]> diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_006.xml b/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_006.xml new file mode 100755 index 0000000..9ea0417 --- /dev/null +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_006.xml @@ -0,0 +1,795 @@ + + + + + a + t + + + # + a + b + c + d + e + f + g + h + i + j + k + l + m + o + p + | + + + # + a + b + c + d + e + f + g + j + | + + + # + a + b + c + d + f + o + q + r + s + | + + + # + 2 + 5 + 6 + a + b + c + d + e + f + g + i + j + k + l + m + n + o + p + q + r + s + t + u + v + w + y + z + | + + + # + a + c + f + i + l + m + o + s + u + z + | + + + 0 + 1 + | + + + 0 + 1 + | + + + 0 + 1 + | + + + + 0 + 1 + d + e + f + h + i + j + m + p + s + u + | + + + # + a + b + c + d + | + + + + + m + + + + # + a + b + c + d + e + f + g + j + | + + + # + o + q + | + + + + a + b + c + d + e + f + g + h + i + j + m + u + z + | + + + + # + a + c + f + i + l + m + o + s + u + z + | + + + + + + e + f + + + # + a + b + c + d + e + f + g + i + j + k + m + z + |||| + + + ## + aa + ab + ac + ad + ae + af + ag + am + an + ap + au + az + ba + bb + bc + bd + be + bf + bg + bh + bi + bj + bk + bl + bo + br + bs + bu + bz + ca + cb + cc + ce + cp + cu + cz + da + db + dc + dd + de + df + dg + dh + dl + zz + | + + + + a + b + c + d + e + f + g + u + z + | + + + + # + a + c + f + i + l + m + o + s + u + z + | + + + # + a + b + c + d + f + o + q + r + s + | + + + + 0 + 1 + | + + + + # + e + j + k + l + n + o + p + r + z + | + + + + + c + d + i + j + + + an + bd + bg + bl + bt + ca + cb + cc + cg + ch + cl + cn + co + cp + cr + cs + ct + cy + cz + df + dv + fg + fl + fm + ft + gm + hy + jz + mc + md + mi + mo + mp + mr + ms + mu + mz + nc + nn + op + or + ov + pg + pm + po + pp + pr + ps + pt + pv + rc + rd + rg + ri + rp + rq + sd + sg + sn + sp + st + su + sy + tc + tl + ts + uu + vi + vr + wz + za + zz + || + + + a + b + c + d + e + g + h + i + j + m + n + u + z + | + + + # + d + e + f + n + u + | + + + # + a + b + c + d + e + f + g + j + | + + + # + a + b + c + d + f + o + q + r + s + | + + + # + a + b + c + d + e + f + g + h + i + k + r + s + z + | + + + # + a + b + c + d + e + f + g + h + i + j + k + l + m + n + o + p + r + s + t + z + | + + + + # + a + b + c + n + u + | + + + + + + s + + + # + a + b + c + d + e + f + g + h + i + j + k + m + q + s + t + u + w + z + | + + + n + r + u + x + | + + + + # + d + l + m + n + p + w + | + + + # + a + b + c + d + e + f + o + q + s + | + + + # + a + b + c + d + f + o + q + r + s + | + + + # + 5 + 6 + a + b + c + d + e + f + g + h + i + k + l + m + n + o + p + q + r + s + t + u + v + w + y + z + | + + + # + 5 + 6 + a + b + c + d + e + f + g + h + i + k + l + m + n + o + p + q + r + s + t + u + v + w + z + ||| + + + # + a + c + f + i + l + m + o + s + u + z + | + + + 0 + 1 + | + + + + # + a + b + c + d + e + f + g + h + i + j + k + l + u + z + | + + + 0 + 1 + 2 + | + + + + + g + k + o + r + + + 000 + 001-999 + nnn + ||| +                         --- + + + + # + a + b + c + d + e + f + g + j + | + + + + # + a + c + f + i + l + m + o + s + u + z + | + + + # + a + b + c + d + f + o + q + r + s + | + + + + a + b + c + d + f + g + i + k + l + m + n + o + p + q + r + s + t + v + w + z + | + + + a + c + l + n + u + z + | + + + + + p + + + + # + a + b + c + d + f + o + q + r + s + | + + + + diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_008.tmpl b/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_008.tmpl old mode 100644 new mode 100755 index 9dddccb..b232466 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_008.tmpl +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_008.tmpl @@ -1,282 +1,335 @@ Koha › Cataloging › 008 builder + + + + + + - +onload="loadXmlValues()">

008 Fixed-length data elements--General information

-
+ + + + + +
+

+ + + - - - - - - - - -
1-5 Date entered on file (auto-filled)" />
- - - +" /> + + + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + - - - + + + + - - + + + + + "/> + - + + + - - + + + + - - - - + + + + + - + - + - + - - + +
+ +
" />
+ + + -
- "/> -
- "/>
See MARC Code List for Countries - "/> -
"/>
+ "/> +
+ "/> +
See MARC Code List for Countries + "/> +
"/> +
- + -
- - + - - + + - + - + - + - + - + - + - -
- "/>
- - + @@ -288,7 +341,7 @@ - + @@ -309,67 +362,67 @@ - + - + - + - + - + - -
- - + - -
- - + @@ -381,7 +434,7 @@
- @@ -400,13 +453,14 @@
32 Undefined
32 Undefined
- @@ -417,12 +471,12 @@ - + - + @@ -436,32 +490,32 @@ - + - + - + - + - + @@ -479,7 +533,7 @@ - + @@ -487,14 +541,13 @@ -
- @@ -514,7 +567,7 @@ - + @@ -523,60 +576,60 @@
See MARC Code List for Languages - "/> + "/>
- + +
- @@ -588,20 +641,21 @@ - + - + - +
Cancel
@@ -611,49 +665,62 @@ // Pad the string with spaces so that it is 4 characters long. // Also, truncate strings that are longer than 4 characters. function pad4(s) { - var pad = ""; - if (s.length < 4) { - var padLength = 4 - s.length; - for (var i = 0; i < 4 - s.length; i++) { - pad += " "; - } - s += pad; - } else { - s = s.substring(0, 4); - } - return s; + var pad = ""; + if (s.length < 4) { + var padLength = 4 - s.length; + for (var i = 0; i < 4 - s.length; i++) { + pad += " "; + } + s += pad; + } else { + s = s.substring(0, 4); + } + return s; } + +function parseField() +{ + var result = ""; + result = document.f_pop.f1.value+ + document.f_pop.f6.value+ + // bug 2563 { + ( document.f_pop.f710.value.match(/^\s*$/) ? " " : pad4(document.f_pop.f710.value) )+ + ( document.f_pop.f1114.value.match(/^\s*$/) ? " " : pad4(document.f_pop.f1114.value) )+ + // } + //MR + (document.f_pop.f1517.value+" ").substr(0,3)+ + (document.f_pop.f1821.value+" ").substr(0,4)+ + document.f_pop.f22.value+ + document.f_pop.f23.value+ + (document.f_pop.f2427.value+" ").substr(0,4)+ + document.f_pop.f28.value+ + document.f_pop.f29.value+ + document.f_pop.f30.value+ + document.f_pop.f31.value+ ' '+ + document.f_pop.f33.value+ + document.f_pop.f34.value+ + //MR + (document.f_pop.f3537.value+" ").substr(0,3)+ + document.f_pop.f38.value+ + document.f_pop.f39.value; + return result; +}//parseField + + function report() { - var doc = opener.document; + var doc = opener.document; var field = doc.getElementById(""); - field.value = - document.f_pop.f1.value+ - document.f_pop.f6.value+ - // bug 2563 { - ( document.f_pop.f710.value.match(/^\s*$/) ? " " : pad4(document.f_pop.f710.value) )+ - ( document.f_pop.f1114.value.match(/^\s*$/) ? " " : pad4(document.f_pop.f1114.value) )+ - // } - //MR - (document.f_pop.f1517.value+" ").substr(0,3)+ - (document.f_pop.f1821.value+" ").substr(0,4)+ - document.f_pop.f22.value+ - document.f_pop.f23.value+ - (document.f_pop.f2427.value+" ").substr(0,4)+ - document.f_pop.f28.value+ - document.f_pop.f29.value+ - document.f_pop.f30.value+ - document.f_pop.f31.value+ ' '+ - document.f_pop.f33.value+ - document.f_pop.f34.value+ - //MR - (document.f_pop.f3537.value+" ").substr(0,3)+ - document.f_pop.f38.value+ - document.f_pop.f39.value; - self.close(); - return false; - } - //]]> + + field.value = document.getElementById("h4_result").innerHTML; + + field.value = parseField(); + + + self.close(); + return false; + } + //]]> diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_008.xml b/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_008.xml new file mode 100755 index 0000000..c8c7295 --- /dev/null +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_008.xml @@ -0,0 +1,1298 @@ + + + + + + b + c + d + e + i + k + m + n + p + q + r + s + t + u + | + + + # + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + u + |||| + + + # + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + u + |||| + + + vp# + xx# + [aa#] + [aaa] + + + # + a + b + c + d + e + f + g + h + i + j + k + l + m + o + p + | + + + # + a + b + c + d + e + f + g + j + | + + + # + a + b + c + d + f + o + q + r + s + | + + + # + 2 + 5 + 6 + a + b + c + d + e + f + g + i + j + k + l + m + n + o + p + q + r + s + t + u + v + w + y + z + | + + + # + a + c + f + i + l + m + o + s + u + z + | + + + 0 + 1 + | + + + 0 + 1 + | + + + 0 + 1 + | + + + + 0 + 1 + d + e + f + h + i + j + m + p + s + u + | + + + # + a + b + c + d + | + + + ### + mul + sgn + und + zxx + [aaa] + + + # + d + o + r + s + x + | + + + # + c + d + u + | + + + + + + b + c + d + e + i + k + m + n + p + q + r + s + t + u + | + + + # + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + u + |||| + + + # + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + u + |||| + + + vp# + xx# + [aa#] + [aaa] + + + + # + a + b + c + d + e + f + g + j + | + + + # + o + q + | + + + + a + b + c + d + e + f + g + h + i + j + m + u + z + | + + + + # + a + c + f + i + l + m + o + s + u + z + | + + + + ### + mul + sgn + und + zxx + [aaa] + + + # + d + o + r + s + x + | + + + # + c + d + u + | + + + + + + b + c + d + e + i + k + m + n + p + q + r + s + t + u + | + + + # + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + u + |||| + + + # + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + u + |||| + + + vp# + xx# + [aa#] + [aaa] + + + # + a + b + c + d + e + f + g + i + j + k + m + z + |||| + + + ## + aa + ab + ac + ad + ae + af + ag + am + an + ap + au + az + ba + bb + bc + bd + be + bf + bg + bh + bi + bj + bk + bl + bo + br + bs + bu + bz + ca + cb + cc + ce + cp + cu + cz + da + db + dc + dd + de + df + dg + dh + dl + zz + | + + + + a + b + c + d + e + f + g + u + z + | + + + + # + a + c + f + i + l + m + o + s + u + z + | + + + # + a + b + c + d + f + o + q + r + s + | + + + + 0 + 1 + | + + + + # + e + j + k + l + n + o + p + r + z + | + + + ### + mul + sgn + und + zxx + [aaa] + + + # + d + o + r + s + x + | + + + # + c + d + u + | + + + + + + b + c + d + e + i + k + m + n + p + q + r + s + t + u + | + + + # + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + u + |||| + + + # + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + u + |||| + + + vp# + xx# + [aa#] + [aaa] + + + an + bd + bg + bl + bt + ca + cb + cc + cg + ch + cl + cn + co + cp + cr + cs + ct + cy + cz + df + dv + fg + fl + fm + ft + gm + hy + jz + mc + md + mi + mo + mp + mr + ms + mu + mz + nc + nn + op + or + ov + pg + pm + po + pp + pr + ps + pt + pv + rc + rd + rg + ri + rp + rq + sd + sg + sn + sp + st + su + sy + tc + tl + ts + uu + vi + vr + wz + za + zz + || + + + a + b + c + d + e + g + h + i + j + m + n + u + z + | + + + # + d + e + f + n + u + | + + + # + a + b + c + d + e + f + g + j + | + + + # + a + b + c + d + f + o + q + r + s + | + + + # + a + b + c + d + e + f + g + h + i + k + r + s + z + | + + + # + a + b + c + d + e + f + g + h + i + j + k + l + m + n + o + p + r + s + t + z + | + + + + # + a + b + c + n + u + | + + + + ### + mul + sgn + und + zxx + [aaa] + + + # + d + o + r + s + x + | + + + # + c + d + u + | + + + + + + b + c + d + e + i + k + m + n + p + q + r + s + t + u + | + + + # + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + u + |||| + + + # + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + u + |||| + + + vp# + xx# + [aa#] + [aaa] + + + # + a + b + c + d + e + f + g + h + i + j + k + m + q + s + t + u + w + z + | + + + n + r + u + x + | + + + + # + d + l + m + n + p + w + | + + + # + a + b + c + d + e + f + o + q + s + | + + + # + a + b + c + d + f + o + q + r + s + | + + + # + 5 + 6 + a + b + c + d + e + f + g + h + i + k + l + m + n + o + p + q + r + s + t + u + v + w + y + z + | + + + # + 5 + 6 + a + b + c + d + e + f + g + h + i + k + l + m + n + o + p + q + r + s + t + u + v + w + z + ||| + + + # + a + c + f + i + l + m + o + s + u + z + | + + + 0 + 1 + | + + + + # + a + b + c + d + e + f + g + h + i + j + k + l + u + z + | + + + 0 + 1 + 2 + | + + + ### + mul + sgn + und + zxx + [aaa] + + + # + d + o + r + s + x + | + + + # + c + d + u + | + + + + + + b + c + d + e + i + k + m + n + p + q + r + s + t + u + | + + + # + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + u + |||| + + + # + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + u + |||| + + + vp# + xx# + [aa#] + [aaa] + + + 000 + 001-999 + nnn + ||| +                         --- + + + + # + a + b + c + d + e + f + g + j + | + + + + # + a + c + f + i + l + m + o + s + u + z + | + + + # + a + b + c + d + f + o + q + r + s + | + + + + a + b + c + d + f + g + i + k + l + m + n + o + p + q + r + s + t + v + w + z + | + + + a + c + l + n + u + z + | + + + ### + mul + sgn + und + zxx + [aaa] + + + # + d + o + r + s + x + | + + + # + c + d + u + | + + + + + + b + c + d + e + i + k + m + n + p + q + r + s + t + u + | + + + # + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + u + |||| + + + # + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9 + u + |||| + + + vp# + xx# + [aa#] + [aaa] + + + + # + a + b + c + d + f + o + q + r + s + | + + + + ### + mul + sgn + und + zxx + [aaa] + + + # + d + o + r + s + x + | + + + # + c + d + u + | + + + diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_CF.xsd b/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_CF.xsd new file mode 100755 index 0000000..7b0b27b --- /dev/null +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/marc21_field_CF.xsd @@ -0,0 +1,83 @@ + + + + Control Field Plugin Type of Materials schema + + + + + + Element indicating the control field + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/kohaversion.pl b/kohaversion.pl old mode 100644 new mode 100755 -- 1.5.6.5