From 20b72f12536025aa821495e50d354c8b2fe8bb9d Mon Sep 17 00:00:00 2001 From: Henri-Damien LAURENT Date: Mon, 12 May 2008 22:48:14 +0200 Subject: [PATCH] Adding Optionnal suggestion creation when renewing subscription. Signed-off-by: Joshua Ferraro --- C4/Serials.pm | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/C4/Serials.pm b/C4/Serials.pm index 78d7e4313d..487f1c0e4e 100644 --- a/C4/Serials.pm +++ b/C4/Serials.pm @@ -1428,14 +1428,16 @@ sub ReNewSubscription { my $sth = $dbh->prepare($query); $sth->execute( $subscription->{biblionumber} ); my $biblio = $sth->fetchrow_hashref; - NewSuggestion( - $user, $subscription->{bibliotitle}, - $biblio->{author}, $biblio->{publishercode}, - $biblio->{note}, '', - '', '', - '', '', - $subscription->{biblionumber} - ); + if (C4::Context->preference("RenewSerialAddsSuggestion")){ + NewSuggestion( + $user, $subscription->{bibliotitle}, + $biblio->{author}, $biblio->{publishercode}, + $biblio->{note}, '', + '', '', + '', '', + $subscription->{biblionumber} + ); + } # renew subscription $query = qq| -- 2.20.1