]> git.evergreen-ils.org Git - Evergreen.git/commit
LP#1413592: Don't change lost/long-overdue fines/fees on zero-balance
authorMike Rylander <mrylander@gmail.com>
Wed, 28 Jan 2015 13:40:20 +0000 (08:40 -0500)
committerMike Rylander <mrylander@gmail.com>
Mon, 16 Feb 2015 13:40:32 +0000 (08:40 -0500)
commite65a76067dae8496ab56bb33f3ae4ef5a38fe026
treea635fd1c2d7d860b240301d6c18aaaa32d703fd1
parentd0455836db7bf38b286857682f929b7af8639e63
LP#1413592: Don't change lost/long-overdue fines/fees on zero-balance

The situation that has been reported as the worst offender for creating
negative balances for folks that do not want that to happen goes like this:

1) Item is lost or goes long-overdue
2) Fees/fines charged
3) Said fees/fines are paid in full
4) Item is found and returned
4a) "Void fines and fees on lost item return" settings are enabled
4b) "Reinstate overdue fines on lost item return" setting is enabled
4c) System dutifully voids the lost fines/fees
4d) System dutifully reinstates the overdue fines

So we add an YAOUS to ensure that when a lost item is returned and the
balance of the transaction is exactly $0, the lost fines and fees are not
voided EVEN IF "void fines and fees on lost/long-overdue return" settings are
enabled, and voided overdue fees are likewise not reinstated EVEN IF
"restore overdue on lost/long-overdue return" settings are enabled.

The reason for the second condition is that the point of this new setting is
to have Evergreen consider zero-balance lost/long-overdue transactions as
"handled", and that they should not automatically change.

Signed-off-by: Mike Rylander <mrylander@gmail.com>
Signed-off-by: Kathy Lussier <klussier@masslnc.org>
Open-ILS/src/perlmods/lib/OpenILS/Application/Circ/Circulate.pm
Open-ILS/src/sql/Pg/950.data.seed-values.sql
Open-ILS/src/sql/Pg/upgrade/XXX.data.avoid_lost_void_on_zero_balance.sql [new file with mode: 0644]