[Koha-cvs] koha/C4/Circulation Circ2.pm [dev_week]
Chris Cormack
chris at katipo.co.nz
Wed Sep 20 21:55:39 CEST 2006
CVSROOT: /sources/koha
Module name: koha
Branch: dev_week
Changes by: Chris Cormack <rangi> 06/09/20 19:55:39
Modified files:
C4/Circulation : Circ2.pm
Log message:
Adding noissuescharge check into canbookbeissued
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/koha/C4/Circulation/Circ2.pm?cvsroot=koha&only_with_tag=dev_week&r1=1.87.2.14.2.8&r2=1.87.2.14.2.9
Patches:
Index: Circ2.pm
===================================================================
RCS file: /sources/koha/koha/C4/Circulation/Circ2.pm,v
retrieving revision 1.87.2.14.2.8
retrieving revision 1.87.2.14.2.9
diff -u -b -r1.87.2.14.2.8 -r1.87.2.14.2.9
--- Circ2.pm 18 Sep 2006 18:32:24 -0000 1.87.2.14.2.8
+++ Circ2.pm 20 Sep 2006 19:55:39 -0000 1.87.2.14.2.9
@@ -3,7 +3,7 @@
package C4::Circulation::Circ2;
-# $Id: Circ2.pm,v 1.87.2.14.2.8 2006/09/18 18:32:24 kados Exp $
+# $Id: Circ2.pm,v 1.87.2.14.2.9 2006/09/20 19:55:39 rangi Exp $
#package to deal with Returns
#written 3/11/99 by olwen at katipo.co.nz
@@ -705,6 +705,7 @@
my %issuingimpossible; # filled with problems that causes the issue to be IMPOSSIBLE
my $iteminformation = getiteminformation($env, 0, $barcode);
my $dbh = C4::Context->dbh;
+
#
# DUE DATE is OK ?
#
@@ -735,8 +736,13 @@
# DEBTS
my $amount = checkaccount($env,$borrower->{'borrowernumber'}, $dbh,$duedate);
- if ($amount >0) {
- $needsconfirmation{DEBT} = $amount;
+ my $noissuescharge = C4::Context->preference("noissuescharge");
+
+ if ($amount >$noissuescharge) {
+ $issuingimpossible{DEBT} = sprintf("%.2f",$amount);
+ }
+ elsif ($amount > 0 && $amount <=$noissuescharge) {
+ $needsconfirmation{DEBT} = sprintf("%.2f",$amount);
}
More information about the Koha-cvs
mailing list