From 3d6b078859c73f3835dcd2bf542d89282e4d9352 Mon Sep 17 00:00:00 2001 From: tonnesen Date: Fri, 5 Jul 2002 16:04:04 +0000 Subject: [PATCH] Fixing some bugs in marcimport.pl that broke uploading marc records. --- acqui.simple/marcimport.pl | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/acqui.simple/marcimport.pl b/acqui.simple/marcimport.pl index 97661642b6..49591d496d 100755 --- a/acqui.simple/marcimport.pl +++ b/acqui.simple/marcimport.pl @@ -24,6 +24,8 @@ use C4::Biblio; use C4::SimpleMarc; use C4::Z3950; +my $input = new CGI; + #------------------ # Constants @@ -37,15 +39,15 @@ my $lc2='#ddaaaa'; my $userid=$ENV{'REMOTE_USER'}; -my $input = new CGI; my $dbh=C4Connect; #------------- # Display output -print $input->header; +print $input->header(); print startpage(); print startmenu('acquisitions'); + #------------- # Process input parameters @@ -83,7 +85,7 @@ if ($file) { SWITCH: { if ($menu eq 'z3950') { z3950menu($dbh,$input); last SWITCH; } - if ($menu eq 'uploadmarc') { uploadmarc(); last SWITCH; } + if ($menu eq 'uploadmarc') { uploadmarc($dbh); last SWITCH; } if ($menu eq 'manual') { manual(); last SWITCH; } mainmenu(); } @@ -678,7 +680,7 @@ sub uploadmarc { use strict; my ($dbh)=@_; - requireDBI($dbh,"uploadmarc"); + requireDBI($dbh,"uploadedmarc"); print "Main Menu
\n"; my $sth=$dbh->prepare("select id,name from uploadedmarc"); @@ -798,7 +800,7 @@ sub AcceptMarcUpload { $input, # CGI parms )=@_; - requireDBI($dbh,"AcceptMarcUpload"); + requireDBI($dbh,"uploadedmarc"); my $name=$input->param('name'); my $data=$input->param('uploadmarc'); @@ -1144,6 +1146,9 @@ sub FormatMarcText { #--------------- # $Log$ +# Revision 1.6.2.33 2002/07/05 16:04:04 tonnesen +# Fixing some bugs in marcimport.pl that broke uploading marc records. +# # Revision 1.6.2.32 2002/06/29 17:33:47 amillar # Allow DEFAULT as input to addz3950search. # Check for existence of pid file (cat crashed otherwise). -- 2.39.5