From 4265937054f00b48ad811530988d87818530c281 Mon Sep 17 00:00:00 2001 From: miker Date: Sat, 9 Sep 2006 14:46:45 +0000 Subject: [PATCH] revert to non-aggregate billing, as backdating wipes fines it should not in the case of a failed billing run (and subsequent aggregate billing) git-svn-id: svn://svn.open-ils.org/ILS/trunk@6034 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- .../Application/Storage/Publisher/action.pm | 23 ++++++++++--------- 1 file changed, 12 insertions(+), 11 deletions(-) diff --git a/Open-ILS/src/perlmods/OpenILS/Application/Storage/Publisher/action.pm b/Open-ILS/src/perlmods/OpenILS/Application/Storage/Publisher/action.pm index c55e72c052..0199d043e9 100644 --- a/Open-ILS/src/perlmods/OpenILS/Application/Storage/Publisher/action.pm +++ b/Open-ILS/src/perlmods/OpenILS/Application/Storage/Publisher/action.pm @@ -592,19 +592,20 @@ sub generate_fines { $current_fine_total += $recuring_fine; $latest_amount += $recuring_fine; $latest_billing_ts = $timestamptz; - - $client->respond( "\t\tAdding aggregate fine of ".$c->recuring_fine." for period starting ".$$timestamptz."\n" ); - } - money::billing->create( - { xact => ''.$c->id, - note => "System Generated Overdue Fine", - billing_type => "Overdue materials", - amount => sprintf('%0.2f', $latest_amount/100), - billing_ts => $latest_billing_ts, - } - ) if ($latest_billing_ts and $latest_amount); + money::billing->create( + { xact => ''.$c->id, + note => "System Generated Overdue Fine", + billing_type => "Overdue materials", + amount => sprintf('%0.2f', $recuring_fine/100), + billing_ts => $timestamptz, + } + ); + + } + $client->respond( "\t\tAdding fines totaling $latest_amount for overdue up to $latest_billing_ts\n" ) + if ($latest_billing_ts and $latest_amount); $self->method_lookup('open-ils.storage.transaction.commit')->run; -- 2.43.2