Bugzilla – Attachment 7404 Details for
Bug 7190
written off fines being refunded
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
[SIGNED-OFF] bug_7190: Do not reverse writeoffs when item is returned
SIGNED-OFF-bug7190-Do-not-reverse-writeoffs-when-i.patch (text/plain), 4.05 KB, created by
Nicole C. Engard
on 2012-02-01 01:00:18 UTC
(
hide
)
Description:
[SIGNED-OFF] bug_7190: Do not reverse writeoffs when item is returned
Filename:
MIME Type:
Creator:
Nicole C. Engard
Created:
2012-02-01 01:00:18 UTC
Size:
4.05 KB
patch
obsolete
>From 23201668c40223a3651fd0a206a0ffd4153804c1 Mon Sep 17 00:00:00 2001 >From: Srdjan Jankovic <srdjan@catalyst.net.nz> >Date: Tue, 31 Jan 2012 15:36:44 +1300 >Subject: [PATCH] [SIGNED-OFF] bug_7190: Do not reverse writeoffs when item is returned > >Signed-off-by: Nicole C. Engard <nengard@bywatersolutions.com> >--- > C4/Circulation.pm | 3 ++- > .../prog/en/modules/members/paycollect.tt | 2 ++ > members/paycollect.pl | 2 ++ > 3 files changed, 6 insertions(+), 1 deletions(-) > >diff --git a/C4/Circulation.pm b/C4/Circulation.pm >index 0b5068c..2bf5d51 100644 >--- a/C4/Circulation.pm >+++ b/C4/Circulation.pm >@@ -1866,10 +1866,11 @@ sub _FixAccountForLostAndReturned { > my $item_id = @_ ? shift : $itemnumber; # Send the barcode if you want that logged in the description > my $dbh = C4::Context->dbh; > # check for charge made for lost book >- my $sth = $dbh->prepare("SELECT * FROM accountlines WHERE (itemnumber = ?) AND (accounttype='L' OR accounttype='Rep') ORDER BY date DESC"); >+ my $sth = $dbh->prepare("SELECT * FROM accountlines WHERE itemnumber = ? AND accounttype IN ('L', 'Rep', 'W') ORDER BY date DESC, accountno DESC"); > $sth->execute($itemnumber); > my $data = $sth->fetchrow_hashref; > $data or return; # bail if there is nothing to do >+ $data->{accounttype} eq 'W' and return; # Written off > > # writeoff this amount > my $offset; >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/paycollect.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/paycollect.tt >index 08ee909..0682aea 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/paycollect.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/paycollect.tt >@@ -94,6 +94,7 @@ function moneyFormat(textObj) { > <form name="payindivfine" onsubmit="return validatePayment(this);" method="post" action="/cgi-bin/koha/members/paycollect.pl"> > <input type="hidden" name="borrowernumber" id="borrowernumber" value="[% borrower.borrowernumber %]" /> > <input type="hidden" name="pay_individual" id="pay_individual" value="[% pay_individual %]" /> >+ <input type="hidden" name="itemnumber" id="itemnumber" value="[% itemnumber %]" /> > <input type="hidden" name="description" id="description" value="[% description %]" /> > <input type="hidden" name="accounttype" id="accounttype" value="[% accounttype %]" /> > <input type="hidden" name="notify_id" id="notify_id" value="[% notify_id %]" /> >@@ -148,6 +149,7 @@ function moneyFormat(textObj) { > <form name="woindivfine" action="/cgi-bin/koha/members/pay.pl" method="post" > > <input type="hidden" name="borrowernumber" id="borrowernumber" value="[% borrower.borrowernumber %]" /> > <input type="hidden" name="pay_individual" id="pay_individual" value="[% pay_individual %]" /> >+ <input type="hidden" name="itemnumber" id="itemnumber" value="[% itemnumber %]" /> > <input type="hidden" name="description" id="description" value="[% description %]" /> > <input type="hidden" name="accounttype" id="accounttype" value="[% accounttype %]" /> > <input type="hidden" name="notify_id" id="notify_id" value="[% notify_id %]" /> >diff --git a/members/paycollect.pl b/members/paycollect.pl >index cbddc05..3037b37 100755 >--- a/members/paycollect.pl >+++ b/members/paycollect.pl >@@ -67,6 +67,7 @@ if ( $individual || $writeoff ) { > my $amount = $input->param('amount'); > my $amountoutstanding = $input->param('amountoutstanding'); > $accountno = $input->param('accountno'); >+ my $itemnumber = $input->param('itemnumber'); > my $description = $input->param('description'); > my $title = $input->param('title'); > my $notify_id = $input->param('notify_id'); >@@ -78,6 +79,7 @@ if ( $individual || $writeoff ) { > amount => $amount, > amountoutstanding => $amountoutstanding, > title => $title, >+ itemnumber => $itemnumber, > description => $description, > notify_id => $notify_id, > notify_level => $notify_level, >-- >1.7.2.3
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 7190
:
7310
|
7395
| 7404