From 5f15ea68e83672eb431f48538431cdbe46df7a5e Mon Sep 17 00:00:00 2001 From: Paul POULAIN Date: Wed, 26 Sep 2007 12:26:31 +0200 Subject: [PATCH] 2 BUGFIX (1 being unimarc specific) : change in plugin handling before this commit, the main (usually $a) entry could not be entered by the librarian. With the new BiblioAddAuthority feature, it's a bad idea : the librarian will be able to enter a value manually, and the authority will be automatically created on the fly Thus the small change in addbiblio.pl This commit also fixes a bug in plugin 4XX (which is unimarc specific) : "Empty" option did not work properly + API convention fix (biblionumber instead of bibnum) Signed-off-by: Chris Cormack --- cataloguing/addbiblio.pl | 18 +++++----- .../value_builder/unimarc_field_4XX.pl | 36 +++++++++---------- .../value_builder/unimarc_field_4XX.tmpl | 4 +-- 3 files changed, 29 insertions(+), 29 deletions(-) diff --git a/cataloguing/addbiblio.pl b/cataloguing/addbiblio.pl index 39c803c616..4616f61aa6 100755 --- a/cataloguing/addbiblio.pl +++ b/cataloguing/addbiblio.pl @@ -316,15 +316,15 @@ sub create_input { } elsif ( $tagslib->{$tag}->{$subfield}->{authtypecode} ) { $subfield_data{marc_value} = - " - {$tag}->{$subfield}->{authtypecode}."&index=$subfield_data{id}','$subfield_data{id}')\">... + " + {$tag}->{$subfield}->{authtypecode}."&index=$subfield_data{id}','$subfield_data{id}')\">... "; # it's a plugin field } diff --git a/cataloguing/value_builder/unimarc_field_4XX.pl b/cataloguing/value_builder/unimarc_field_4XX.pl index cb409212b0..75b71040a3 100755 --- a/cataloguing/value_builder/unimarc_field_4XX.pl +++ b/cataloguing/value_builder/unimarc_field_4XX.pl @@ -83,7 +83,7 @@ sub plugin { my $searchdesc; if ( $op eq "fillinput" ) { - my $bibnum = $query->param('bibnum'); + my $biblionumber = $query->param('biblionumber'); my $index = $query->param('index'); my $marcrecord; @@ -101,9 +101,9 @@ sub plugin { ); #get marc record - $marcrecord = GetMarcBiblio($bibnum); + $marcrecord = GetMarcBiblio($biblionumber); - my $subfield_value_9 = $bibnum; + my $subfield_value_9 = $biblionumber; my $subfield_value_0; $subfield_value_0 = $marcrecord->field('001')->data if $marcrecord->field('001'); @@ -293,21 +293,21 @@ sub plugin { $template->param( fillinput => 1, index => $query->param('index') . "", - biblionumber => $bibnum ? $bibnum : "", - subfield_value_9 => $subfield_value_9, - subfield_value_0 => $subfield_value_0, - subfield_value_a => $subfield_value_a, - subfield_value_c => $subfield_value_c, - subfield_value_d => $subfield_value_d, - subfield_value_e => $subfield_value_e, - subfield_value_h => $subfield_value_h, - subfield_value_i => $subfield_value_i, - subfield_value_p => $subfield_value_p, - subfield_value_t => $subfield_value_t, - subfield_value_u => $subfield_value_u, - subfield_value_v => $subfield_value_v, - subfield_value_x => $subfield_value_x, - subfield_value_y => $subfield_value_y, + biblionumber => $biblionumber ? $biblionumber : "", + subfield_value_9 => "$subfield_value_9", + subfield_value_0 => "$subfield_value_0", + subfield_value_a => "$subfield_value_a", + subfield_value_c => "$subfield_value_c", + subfield_value_d => "$subfield_value_d", + subfield_value_e => "$subfield_value_e", + subfield_value_h => "$subfield_value_h", + subfield_value_i => "$subfield_value_i", + subfield_value_p => "$subfield_value_p", + subfield_value_t => "$subfield_value_t", + subfield_value_u => "$subfield_value_u", + subfield_value_v => "$subfield_value_v", + subfield_value_x => "$subfield_value_x", + subfield_value_y => "$subfield_value_y", ); ############################################################### } diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/unimarc_field_4XX.tmpl b/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/unimarc_field_4XX.tmpl index effe7adfd4..eac7ff7463 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/unimarc_field_4XX.tmpl +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/value_builder/unimarc_field_4XX.tmpl @@ -161,9 +161,9 @@ - &bibnum=&type=intranet&op=fillinput')">Choose + &biblionumber=&type=intranet&op=fillinput')">Choose - &bibnum=&type=intranet&op=fillinput')">Clear Field + &type=intranet&op=fillinput')">Clear Field -- 2.39.5