[Koha-bugs] [Bug 8939] New: Fines Charged During Grace Period
bugzilla-daemon at bugs.koha-community.org
bugzilla-daemon at bugs.koha-community.org
Thu Oct 18 01:33:26 CEST 2012
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=8939
Priority: P5 - low
Change sponsored?: ---
Bug ID: 8939
CC: gmcharlt at gmail.com, kyle.m.hall at gmail.com
Assignee: koha-bugs at lists.koha-community.org
Summary: Fines Charged During Grace Period
Severity: major
Classification: Unclassified
OS: Linux
Reporter: williams at amigos.org
Hardware: PC
Status: NEW
Version: rel_3_8
Component: Circulation
Product: Koha
When grace period specified in a circulation rule is greater than one day
(fines charged daily) and a user returns an item (matching the circ rule)
within the grace period, the fine is charged rather than ignored (zero). In one
example, with a 14-day grace period, the fines log produced nightly by fines.pl
shows:
22903 STU [snipped] 122222 2012-09-29 23:59:00 2 4
22951 STU [snipped] 125741 2012-10-11 23:59:00 -10 1
22965 STU [snipped] 77536 2012-10-14 23:59:00 -13 0.25
The negative numbers indicate how many days of grace period remain (-10 means
the item is 4 days overdue); positive numbers shows how many days is overdue
after the grace period. The negative values should result in no processing.
There appears to be an error in the if condition that determines whether to
process/charge a fine on an overdue (negative values result in a TRUE as well
as positive values):
if ($data->{'chargeperiod'} && $units_minus_grace ) {
would work as expected if the second condition is changed:
if ($data->{'chargeperiod'} && ($units_minus_grace > 0) ) {
I've tested on 3.8.3 (Debian package installation) and the change works for
daily accruing fines. I have not yet tested using an hourly fine rule, but
after a quick glance it seems it should work as well.
I'll try (I'm new to Git) to add/submit a patch next.
--
You are receiving this mail because:
You are the assignee for the bug.
You are watching all bug changes.
More information about the Koha-bugs
mailing list