From c415293609263099295c3a892f13efbd6a892a3c Mon Sep 17 00:00:00 2001 From: rangi Date: Sat, 26 Jun 2004 23:45:46 +0000 Subject: [PATCH] Subjects and additional authors now added at this point --- acqui.simple/savebiblio.pl | 41 +++++++++++++++++++++++--------------- 1 file changed, 25 insertions(+), 16 deletions(-) diff --git a/acqui.simple/savebiblio.pl b/acqui.simple/savebiblio.pl index dd1f3c2617..8cb587ad35 100755 --- a/acqui.simple/savebiblio.pl +++ b/acqui.simple/savebiblio.pl @@ -1,6 +1,5 @@ #!/usr/bin/perl - # Copyright 2000-2002 Katipo Communications # # This file is part of Koha. @@ -23,24 +22,34 @@ use strict; use C4::Catalogue; use C4::Biblio; -my $input = new CGI; +my $input = new CGI; my $biblio = { - title => $input->param('title'), - subtitle => $input->param('subtitle')?$input->param('subtitle'):"", - author => $input->param('author')?$input->param('author'):"", - seriestitle => $input->param('seriestitle')?$input->param('seriestitle'):"", - copyrightdate => $input->param('copyrightdate')?$input->param('copyrightdate'):"", - abstract => $input->param('abstract')?$input->param('abstract'):"", - notes => $input->param('notes')?$input->param('notes'):"" -}; # my $biblio + title => $input->param('title'), + subtitle => $input->param('subtitle') ? $input->param('subtitle') : "", + author => $input->param('author') ? $input->param('author') : "", + seriestitle => $input->param('seriestitle') ? $input->param('seriestitle') + : "", + copyrightdate => $input->param('copyrightdate') + ? $input->param('copyrightdate') + : "", + abstract => $input->param('abstract') ? $input->param('abstract') : "", + notes => $input->param('notes') ? $input->param('notes') : "" +}; # my $biblio + +my $subjectheadings = $input->param('subjectheadings'); +my @subjects = split ( /\n/, $subjectheadings ); my $biblionumber; +my $aauthors = $input->param('additionalauthors'); +my @authors = split ( /\n/, $aauthors ); +my $force = $input->param('force'); -if (! $biblio->{'title'}) { +if ( !$biblio->{'title'} ) { print $input->redirect('addbiblio-nomarc.pl?error=notitle'); -} else { - +} +else { $biblionumber = &newbiblio($biblio); - &newsubtitle($biblionumber, $biblio->{'subtitle'}); - + &newsubtitle( $biblionumber, $biblio->{'subtitle'} ); + my $error = modsubject( $biblionumber, 1, @subjects ); + modaddauthor( $biblionumber, @authors ); print $input->redirect("additem-nomarc.pl?biblionumber=$biblionumber"); -} # else +} # else -- 2.39.5