From 2c64e7e0995da6e6a04383db559692915c27fd3e Mon Sep 17 00:00:00 2001 From: Paul POULAIN Date: Fri, 16 Nov 2007 18:49:24 -0600 Subject: [PATCH] bugfix : don't show previously entered values again after saving an item it's confusing and useless Signed-off-by: Chris Cormack Signed-off-by: Joshua Ferraro --- cataloguing/additem.pl | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/cataloguing/additem.pl b/cataloguing/additem.pl index e06ab86be0..a82b621b42 100755 --- a/cataloguing/additem.pl +++ b/cataloguing/additem.pl @@ -155,16 +155,16 @@ if ($op eq "additem") { my @indicator = $input->param('indicator'); # my $itemnumber = $input->param('itemnumber'); my $xml = TransformHtmlToXml(\@tags,\@subfields,\@values,\@indicator,\@ind_tag,'ITEM'); - $itemrecord=MARC::Record::new_from_xml($xml, 'UTF-8'); + my $itemtosave=MARC::Record::new_from_xml($xml, 'UTF-8'); # MARC::Record builded => now, record in DB # warn "R: ".$record->as_formatted; # check that the barcode don't exist already - my $addedolditem = TransformMarcToKoha($dbh,$itemrecord); + my $addedolditem = TransformMarcToKoha($dbh,$itemtosave); my $exist_itemnumber = get_item_from_barcode($addedolditem->{'barcode'}); if ($exist_itemnumber && $exist_itemnumber != $itemnumber) { push @errors,"barcode_not_unique"; } else { - my ($oldbiblionumber,$oldbibnum,$oldbibitemnum) = ModItem($itemrecord,$biblionumber,$itemnumber,0); + my ($oldbiblionumber,$oldbibnum,$oldbibitemnum) = ModItem($itemtosave,$biblionumber,$itemnumber,0); $itemnumber=""; } $nextop="additem"; -- 2.11.0