Bugzilla – Attachment 82948 Details for
Bug 21849
Offsets not stored correctly in _FixOverduesOnReturn
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 21849: Two useless Koha::Account::Offset->new calls need attention
Bug-21849-Two-useless-KohaAccountOffset-new-calls-.patch (text/plain), 1.77 KB, created by
Marcel de Rooy
on 2018-12-07 06:44:13 UTC
(
hide
)
Description:
Bug 21849: Two useless Koha::Account::Offset->new calls need attention
Filename:
MIME Type:
Creator:
Marcel de Rooy
Created:
2018-12-07 06:44:13 UTC
Size:
1.77 KB
patch
obsolete
>From a7e3aa30aa4caff47dc29ea3c6a4c33954d2b7ee Mon Sep 17 00:00:00 2001 >From: Kyle M Hall <kyle@bywatersolutions.com> >Date: Fri, 16 Nov 2018 07:01:39 -0500 >Subject: [PATCH] Bug 21849: Two useless Koha::Account::Offset->new calls need > attention >Content-Type: text/plain; charset=utf-8 > >Came across those calls in bug 20598 in _FixOverduesOnReturn > > Koha::Account::Offset->new( > { > debit_id => $accountline->id, > type => 'Forgiven', > amount => $amountoutstanding * -1, > } > ); > >This does nothing if you don't store data. > >Test Plan: >1) Apply this patch >2) Set up 2 items with overdue fines >3) Return one with dropbox mode >4) Note the dropbox account offset is created >5) Return one with full fine forgiveness >6) Note the forgiven account offset is created > >Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> > >Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >--- > C4/Circulation.pm | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > >diff --git a/C4/Circulation.pm b/C4/Circulation.pm >index 0999a97..4d252c6 100644 >--- a/C4/Circulation.pm >+++ b/C4/Circulation.pm >@@ -2339,7 +2339,7 @@ sub _FixOverduesOnReturn { > type => 'Forgiven', > amount => $amountoutstanding * -1, > } >- ); >+ )->store(); > > if (C4::Context->preference("FinesLog")) { > &logaction("FINES", 'MODIFY',$borrowernumber,"Overdue forgiven: item $item"); >@@ -2354,7 +2354,7 @@ sub _FixOverduesOnReturn { > type => 'Dropbox', > amount => $accountline->lastincrement * -1, > } >- ); >+ )->store(); > > if ( C4::Context->preference("FinesLog") ) { > &logaction( "FINES", 'MODIFY', $borrowernumber, >-- >2.1.4
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 21849
:
82397
|
82404
|
82919
|
82920
|
82947
| 82948