Bug 22873 - C4::SIP::ILS::Transation::FeePayment->pay $disallow_overpayment does nothing
Summary: C4::SIP::ILS::Transation::FeePayment->pay $disallow_overpayment does nothing
Status: RESOLVED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: SIP2 (show other bugs)
Version: Main
Hardware: All All
: P5 - low trivial
Assignee: Kyle M Hall (khall)
QA Contact: Testopia
URL:
Keywords:
Depends on: 16899
Blocks:
  Show dependency treegraph
 
Reported: 2019-05-09 10:05 UTC by Martin Renvoize (ashimema)
Modified: 2024-06-27 12:35 UTC (History)
4 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Trivial patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
23.11.00,23.05.05,22.11.11
Circulation function:


Attachments
Bug 22873: Add comment to explain what disallow_overpayment is for (813 bytes, patch)
2023-09-25 14:11 UTC, Kyle M Hall (khall)
Details | Diff | Splinter Review
Bug 22873: Add comment to explain what disallow_overpayment is for (868 bytes, patch)
2023-09-25 14:17 UTC, Kyle M Hall (khall)
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Renvoize (ashimema) 2019-05-09 10:05:13 UTC
The `disallow_overpayment` parameter that's expected to be passed to the pay method of FeePayment does nothing.. it should either be removed or implimented.
Comment 1 Katrin Fischer 2019-05-11 23:23:51 UTC
I am not sure that this does nothing, there is some code in FeePayment.pm that checks for it:

if ($disallow_overpayment) {
    return 0 if $account->balance < $amt;
}
Comment 2 Andrew Fuerste-Henry 2020-07-08 19:28:01 UTC
I'm looking at a couple patrons on a 19.11 install where payments were double-submitted. The first payment set the amountoutstanding on the fine to 0. The second payment posted to their account and tied to the fine via account_offsets, but with $0 applied. So the payment wasn't refused, but Koha knew enough not to make the fine have a negative amount due.
Comment 3 Kyle M Hall (khall) 2020-07-09 13:35:02 UTC
It is used in a SIP option. Take a look at etc/SIPconfig.xml in master.
Comment 4 Katrin Fischer 2023-09-23 16:51:40 UTC
(In reply to Kyle M Hall from comment #3)
> It is used in a SIP option. Take a look at etc/SIPconfig.xml in master.

So should this be closed?
Comment 5 Kyle M Hall (khall) 2023-09-25 13:59:22 UTC
(In reply to Katrin Fischer from comment #4)
> (In reply to Kyle M Hall from comment #3)
> > It is used in a SIP option. Take a look at etc/SIPconfig.xml in master.
> 
> So should this be closed?

Let's add a comment so future devs will know what it is there.
Comment 6 Kyle M Hall (khall) 2023-09-25 14:11:26 UTC
Created attachment 156168 [details] [review]
Bug 22873: Add comment to explain what disallow_overpayment is for
Comment 7 Kyle M Hall (khall) 2023-09-25 14:17:54 UTC
Created attachment 156169 [details] [review]
Bug 22873: Add comment to explain what disallow_overpayment is for

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Comment 8 Tomás Cohen Arazi (tcohen) 2023-10-04 13:33:22 UTC
Pushed to master for 23.11.

Nice work everyone, thanks!
Comment 9 Fridolin Somers 2023-10-05 20:22:23 UTC
Pushed to 23.05.x for 23.05.05
Comment 10 Matt Blenkinsop 2023-10-17 17:24:21 UTC
Nice work everyone!

Pushed to oldstable for 22.11.x