Bugzilla – Attachment 102553 Details for
Bug 24266
Noisy error in reconcile_balances.pl
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 24266: (alternate patch) Only use defined borrowernumbers in reconcile_balances.pl cron
Bug-24266-alternate-patch-Only-use-defined-borrowe.patch (text/plain), 1.77 KB, created by
Martin Renvoize (ashimema)
on 2020-04-08 11:05:42 UTC
(
hide
)
Description:
Bug 24266: (alternate patch) Only use defined borrowernumbers in reconcile_balances.pl cron
Filename:
MIME Type:
Creator:
Martin Renvoize (ashimema)
Created:
2020-04-08 11:05:42 UTC
Size:
1.77 KB
patch
obsolete
>From c621ef74338a797dd73788a1cd9324108c801ae0 Mon Sep 17 00:00:00 2001 >From: Aleisha Amohia <aleishaamohia@hotmail.com> >Date: Mon, 16 Mar 2020 22:09:51 +0000 >Subject: [PATCH] Bug 24266: (alternate patch) Only use defined borrowernumbers > in reconcile_balances.pl cron > >I believe the error is triggered when borrowernumbers are left empty in >the accountlines table. Not sure why this would happen, but it appears >to be what causes the problem. > >Do not apply the first patch if testing this patch. > >To test: >1) sudo koha-mysql INSTANCENAME >2) Create a test borrower, add any payment etc to create an accountline, > then delete this borrower >3) ensure the AccountAutoReconcile syspref is disabled >4) Go to another borrower's accounting tab >5) Create a manual credit or debit. Confirm this shows in the 'Make a >payment' tab as an amount that COULD be applied, but isn't automatically >applied >6) in your terminal, run the reconcile_balances.pl script >7) Confirm the error does not show in the logs and the balance for >the borrower is correctly reconciled. > >Sponsored-by: Horowhenua District Council >Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> >--- > misc/cronjobs/reconcile_balances.pl | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > >diff --git a/misc/cronjobs/reconcile_balances.pl b/misc/cronjobs/reconcile_balances.pl >index 0dcae6cb13..0202de9450 100755 >--- a/misc/cronjobs/reconcile_balances.pl >+++ b/misc/cronjobs/reconcile_balances.pl >@@ -81,7 +81,8 @@ cronlogaction(); > > my @patron_ids = map { $_->borrowernumber } Koha::Account::Lines->search( > { >- amountoutstanding => { '<' => 0 } >+ amountoutstanding => { '<' => 0 }, >+ borrowernumber => { '!=' => undef } > }, > { > columns => [ qw/borrowernumber/ ], >-- >2.20.1
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 24266
:
96484
|
100832
|
100926
|
102553
|
102680