fixed mark-lost to not charge the default price if the price is explicitly set to...
authorerickson <erickson@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Fri, 6 Oct 2006 14:57:21 +0000 (14:57 +0000)
committererickson <erickson@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Fri, 6 Oct 2006 14:57:21 +0000 (14:57 +0000)
git-svn-id: svn://svn.open-ils.org/ILS/trunk@6403 dcc99617-32d9-48b4-a31d-7c20da2025e4

Open-ILS/src/perlmods/OpenILS/Application/Circ.pm

index 7ba59bd..cb432bc 100644 (file)
@@ -309,9 +309,10 @@ sub _set_circ_lost {
        my $fee = $settings->{'circ.lost_materials_processing_fee'} || 0;
 
        # If the copy has a price configured, charge said price to the user
+       # otherwise use the default price
        my $s = OILS_SETTING_DEF_ITEM_PRICE;
-       my $copy_price = $copy->price || 0;
-       $copy_price = $settings->{$s} unless $copy_price and $copy_price > 0;
+       my $copy_price = $copy->price;
+       $copy_price = $settings->{$s} unless defined $copy_price;
        if($copy_price and $copy_price > 0) {
                $logger->debug("lost copy has a price of $copy_price");
                $evt = _make_bill($session, $copy_price, 'Lost Materials', $circ->id);