From fe9e11db3617accc9222f299d31c44c606164fab Mon Sep 17 00:00:00 2001 From: Martin Renvoize Date: Fri, 15 Mar 2019 13:29:00 +0000 Subject: [PATCH] Bug 22518: Remove references to 'O' accounttype I went back over 12 years to and still only found "FIXME: What are these accounttypes" concerning the 'O' type and I couldn't find anywhere where it was being set. Signed-off-by: Martin Renvoize Signed-off-by: Josef Moravec --- C4/Circulation.pm | 5 +---- C4/Overdues.pm | 3 +-- Koha/Account.pm | 2 -- misc/maintenance/fix_accountlines_date.pl | 2 +- 4 files changed, 3 insertions(+), 9 deletions(-) diff --git a/C4/Circulation.pm b/C4/Circulation.pm index 7ab1db7e82..42f7211c71 100644 --- a/C4/Circulation.pm +++ b/C4/Circulation.pm @@ -2329,10 +2329,7 @@ sub _FixOverduesOnReturn { { borrowernumber => $borrowernumber, itemnumber => $item, - -or => [ - accounttype => 'FU', - accounttype => 'O', - ], + accounttype => 'FU' } )->next(); return 0 unless $accountline; # no warning, there's just nothing to fix diff --git a/C4/Overdues.pm b/C4/Overdues.pm index de23dd906d..ae6b8ce4d0 100644 --- a/C4/Overdues.pm +++ b/C4/Overdues.pm @@ -530,7 +530,6 @@ sub UpdateFine { # "A" is Account Management Fee # "N" is New Card # "M" is Sundry - # "O" is Overdue ?? # "F" is Fine ?? # "FU" is Fine UPDATE?? # "Pay" is Payment @@ -538,7 +537,7 @@ sub UpdateFine { my $sth = $dbh->prepare( "SELECT * FROM accountlines WHERE borrowernumber=? AND - (( accounttype IN ('O','F','M') AND amountoutstanding<>0 ) OR + (( accounttype IN ('F','M') AND amountoutstanding<>0 ) OR accounttype = 'FU' )" ); $sth->execute( $borrowernumber ); diff --git a/Koha/Account.pm b/Koha/Account.pm index ddd60127ef..b6034914d4 100644 --- a/Koha/Account.pm +++ b/Koha/Account.pm @@ -417,7 +417,6 @@ $debit_type can be any of: - processing - rent - reserve - - overdue - manual =cut @@ -703,7 +702,6 @@ our $account_type_debit = { 'processing' => 'PF', 'rent' => 'Rent', 'reserve' => 'Res', - 'overdue' => 'O', 'manual_debit' => 'M', 'hold_expired' => 'HE' }; diff --git a/misc/maintenance/fix_accountlines_date.pl b/misc/maintenance/fix_accountlines_date.pl index 34ee55a544..30479f469a 100755 --- a/misc/maintenance/fix_accountlines_date.pl +++ b/misc/maintenance/fix_accountlines_date.pl @@ -129,7 +129,7 @@ $dbh->{AutoCommit} = 0; my $sth = $dbh->prepare(" SELECT accountlines_id, description FROM accountlines - WHERE accounttype in ('FU', 'F', 'O', 'M') + WHERE accounttype in ('FU', 'F', 'M') ;"); $sth->execute(); -- 2.11.0