]> git.koha-community.org Git - koha.git/commit
Bug 12596 - Backdating returns with SpecifiyReturnDate causes fines for items not...
authorKyle M Hall <kyle@bywatersolutions.com>
Thu, 17 Jul 2014 14:57:06 +0000 (10:57 -0400)
committerGalen Charlton <gmc@esilibrary.com>
Tue, 26 Aug 2014 22:39:12 +0000 (22:39 +0000)
commit462c33aeb6a71eb8c5d9afa98d05b7f48b7d742f
treee1bb7b4096d995ddf8e5db1051e0e29a32171542
parent90328d0811c8c253188a4cb6192d9a6915fcd68a
Bug 12596 - Backdating returns with SpecifiyReturnDate causes fines for items not overdue!

When using the backdating of returns feature, an item that is not
overdue is treated as being as many days overdue as it is *not* overdue.
This is due to the fact that _get_chargeable_units appears to return the
difference between the return date and the due date without
consideration the return date being earlier than the due date.

Test Plan:
1) Apply the unit test patch
2) prove t/db_dependent/Circulation.t
3) Note the failure
4) Apply the second patch
5) prove t/db_dependent/Circulation.t
6) Note there are no failures

Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Fixes some badly named variables also

Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
In order to test this, you need to activate SpecifyReturnDate.
I confirmed the problem and verified that the bug fixes it
by running the tests, but also by testing in staff.

Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Signed-off-by: Galen Charlton <gmc@esilibrary.com>
C4/Overdues.pm