From be17cb44bfd7f694b624267526af395e9e16faae Mon Sep 17 00:00:00 2001 From: Chris Cormack Date: Fri, 12 Aug 2011 10:23:59 +1200 Subject: [PATCH] Bug 6713, editing matching rules broken Was a template error, but also a bug that had been in there for a while fixed too Please test by editing a matching rule, match sure no new match checks are added, and that the matchpoint components survive. Then try importing some marc records using that match rule --- admin/matching-rules.pl | 2 +- .../prog/en/modules/admin/matching-rules.tt | 98 ++++++++++---------- 2 files changed, 50 insertions(+), 50 deletions(-) diff --git a/admin/matching-rules.pl b/admin/matching-rules.pl index 63e5a3f..e992899 100755 --- a/admin/matching-rules.pl +++ b/admin/matching-rules.pl @@ -126,7 +126,7 @@ sub add_update_matching_rule { # match checks my @mc_nums = sort map { /^mc_(\d+)_id/ ? int($1): () } $input->param; - foreach my $mc_num (@mp_nums) { + foreach my $mc_num (@mc_nums) { # source components my $src_components = []; my @src_comp_nums = sort map { /^mc_${mc_num}_src_c_(\d+)_tag/ ? int($1): () } $input->param; diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/matching-rules.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/matching-rules.tt index 9b1be24..1c0a009 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/matching-rules.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/matching-rules.tt @@ -250,42 +250,42 @@ function CheckRuleForm(f) { [% FOREACH component IN matchpoint.components %] -
+
Matchpoint components
  1. - - Tag: +
  2. - - Subfields: +
  3. - - Offset: +
  4. - - Length: +
  5. [% FOREACH norm IN component.norms %] -
  6. - - + +
  7. @@ -362,37 +362,37 @@ function CheckRuleForm(f) {
    1. -
    2. - - Subfields: +
    3. - - Offset: +
    4. - - Length: +
    5. [% FOREACH norm IN src_component.norms %] -
    6. - - + +
    7. @@ -401,42 +401,42 @@ function CheckRuleForm(f) {
[% END %] [% FOREACH tgt_component IN matchcheck.tgt_components %] -
+
Target (database) record check field
  1. - - Tag: +
  2. - - Subfields: +
  3. - - Offset: +
  4. - - Length: +
  5. [% FOREACH norm IN tgt_component.norms %] -
  6. - - + +
  7. -- 1.7.4.1