View | Details | Raw Unified | Return to bug 9129
Collapse All | Expand All

(-)a/C4/Overdues.pm (+4 lines)
Lines 268-275 sub CalcFine { Link Here
268
    } else {
268
    } else {
269
        # a zero (or null) chargeperiod or negative units_minus_grace value means no charge.
269
        # a zero (or null) chargeperiod or negative units_minus_grace value means no charge.
270
    }
270
    }
271
271
    $amount = $data->{overduefinescap} if $data->{overduefinescap} && $amount > $data->{overduefinescap};
272
    $amount = $data->{overduefinescap} if $data->{overduefinescap} && $amount > $data->{overduefinescap};
273
    $amount = $item->{'replacementprice'} if ( C4::Context->preference('MaxFineIsReplacementPrice') && $item->{'replacementprice'} && $amount > $item->{'replacementprice'} );
274
272
    $debug and warn sprintf("CalcFine returning (%s, %s, %s, %s)", $amount, $data->{'chargename'}, $units_minus_grace, $chargeable_units);
275
    $debug and warn sprintf("CalcFine returning (%s, %s, %s, %s)", $amount, $data->{'chargename'}, $units_minus_grace, $chargeable_units);
276
273
    return ($amount, $data->{'chargename'}, $units_minus_grace, $chargeable_units);
277
    return ($amount, $data->{'chargename'}, $units_minus_grace, $chargeable_units);
274
    # FIXME: chargename is NEVER populated anywhere.
278
    # FIXME: chargename is NEVER populated anywhere.
275
}
279
}
(-)a/installer/data/mysql/sysprefs.sql (+1 lines)
Lines 386-388 INSERT INTO systempreferences (variable,value,explanation,type) VALUES('OPACdidy Link Here
386
INSERT INTO systempreferences (variable,value,explanation,type) VALUES('INTRAdidyoumean',NULL,'Did you mean? configuration for the Intranet. Do not change, as this is controlled by /cgi-bin/koha/admin/didyoumean.pl.','Free');
386
INSERT INTO systempreferences (variable,value,explanation,type) VALUES('INTRAdidyoumean',NULL,'Did you mean? configuration for the Intranet. Do not change, as this is controlled by /cgi-bin/koha/admin/didyoumean.pl.','Free');
387
INSERT INTO systempreferences (variable, value, options, explanation, type) VALUES ('BlockReturnOfWithdrawnItems', '1', '0', 'If enabled, items that are marked as withdrawn cannot be returned.', 'YesNo');
387
INSERT INTO systempreferences (variable, value, options, explanation, type) VALUES ('BlockReturnOfWithdrawnItems', '1', '0', 'If enabled, items that are marked as withdrawn cannot be returned.', 'YesNo');
388
INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('HoldsToPullStartDate','2','Set the default start date for the Holds to pull list to this many days ago',NULL,'Integer');
388
INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('HoldsToPullStartDate','2','Set the default start date for the Holds to pull list to this many days ago',NULL,'Integer');
389
INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('MaxFineIsReplacementPrice',0,'Make the replacement price a second max fine ceiling.',NULL,'YesNo');
(-)a/installer/data/mysql/updatedatabase.pl (+8 lines)
Lines 6063-6068 if (C4::Context->preference("Version") < TransformToNum($DBversion)) { Link Here
6063
}
6063
}
6064
6064
6065
6065
6066
$DBversion = "3.09.00.XXX";
6067
if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
6068
   $dbh->do("INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('MaxFineIsReplacementPrice',0,'Make the replacement price a second max fine ceiling.',NULL,'YesNo')");
6069
   print "Upgrade to $DBversion done (Bug 9107: Add syspref MaxFineIsReplacementPrice)\n";
6070
   SetVersion ($DBversion);
6071
}
6072
6073
6066
=head1 FUNCTIONS
6074
=head1 FUNCTIONS
6067
6075
6068
=head2 TableExists($table)
6076
=head2 TableExists($table)
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/patrons.pref (-1 / +6 lines)
Lines 80-85 Patrons: Link Here
80
         - '[% local_currency %].'
80
         - '[% local_currency %].'
81
         - Empty value means no limit. Single item caps are specified in the circulation rules matrix.
81
         - Empty value means no limit. Single item caps are specified in the circulation rules matrix.
82
     -
82
     -
83
         - pref: MaxFineIsReplacementPrice
84
           choices:
85
               yes: Allow
86
               no: "Don't allow"
87
         - the maximum fine for an item to exceed the replacement price for that item.
88
     -
83
         - pref: memberofinstitution
89
         - pref: memberofinstitution
84
           choices:
90
           choices:
85
               yes: Do
91
               yes: Do
86
- 

Return to bug 9129