Bugzilla – Attachment 68754 Details for
Bug 11210
Allow partial writeoff
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 11210 - Writeoff partial amounts
Bug-11210---Writeoff-partial-amounts.patch (text/plain), 3.93 KB, created by
Kyle M Hall (khall)
on 2017-10-27 15:36:50 UTC
(
hide
)
Description:
Bug 11210 - Writeoff partial amounts
Filename:
MIME Type:
Creator:
Kyle M Hall (khall)
Created:
2017-10-27 15:36:50 UTC
Size:
3.93 KB
patch
obsolete
>From f3f485c643bb608a820d361ec5196e31fd5bb6f0 Mon Sep 17 00:00:00 2001 >From: David Bourgault <david.bourgault@inlibro.com> >Date: Mon, 25 Sep 2017 13:05:01 -0400 >Subject: [PATCH] Bug 11210 - Writeoff partial amounts > >Minor changes to pay.pl and paycollect.tt to allow writing off a partial amount of a fine. > >Test plan: >0) Go to the Fines tab of a test patron's profile >1) Create a fine if there are none (under the Manual invoice tab) >2) Go to the "Pay fines" tab >3) Press the write off button on the corresponding account line > >Without patch, you'll be asked to confirm, but will not be able to edit the amount >With patch, you'll be able to edit the amount. > >Followed test plan, patch worked as described. Also ran QA test tool and >modified files passed > >Signed-off-by: Alex Buckley <alexbuckley@catalyst.net.nz> > >Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> >--- > .../intranet-tmpl/prog/en/modules/members/paycollect.tt | 15 +++++++++++---- > members/pay.pl | 2 +- > 2 files changed, 12 insertions(+), 5 deletions(-) > >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 a1458b5..cac4d8c 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/paycollect.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/paycollect.tt >@@ -165,7 +165,6 @@ function moneyFormat(textObj) { > <input type="hidden" name="notify_id" id="notify_id" value="[% notify_id %]" /> > <input type="hidden" name="notify_level" id="notify_level" value="[% notify_level %]" /> > <input type="hidden" name="amount" id="amount" value="[% amount %]" /> >- <input type="hidden" name="amountoutstanding" id="amountoutstanding" value="[% amountoutstanding %]" /> > <input type="hidden" name="accountlines_id" id="accountlines_id" value="[% accountlines_id %]" /> > <input type="hidden" name="title" id="title" value="[% title %]" /> > <input type="hidden" name="payment_note" id="payment_note" value="[% payment_note %]" /> >@@ -178,7 +177,7 @@ function moneyFormat(textObj) { > <th>Amount</th> > <th>Amount outstanding</th> > </tr></thead> >- <tfoot><td colspan="5">Total amount to be written off:</td><td>[% amountoutstanding | format('%.2f') %]</td></tfoot> >+ <tfoot><td colspan="5">Total amount outstanding:</td><td>[% amountoutstanding | format('%.2f') %]</td></tfoot> > <tbody><tr> > <td>[% description %] [% title %]</td> > <td>[% accounttype %]</td> >@@ -188,8 +187,16 @@ function moneyFormat(textObj) { > <td class="debit">[% amountoutstanding | format('%.2f') %]</td> > </tr></tbody> > </table> >- </fieldset> >- <div class="action"><input type="submit" name="confirm_writeoff" id="confirm_writeoff" value="Write off this charge" /> >+ >+ <ol> >+ <li> >+ <label for="paid">Writeoff amount: </label> >+ <!-- default to writing off all --> >+ <input name="amountwrittenoff" id="amountwrittenoff" value="[% amountoutstanding | format('%.2f') %]" /> >+ </li> >+ </ol> >+ </fieldset> >+ <div class="action"><input type="submit" name="confirm_writeoff" id="confirm_writeoff" value="Write off this charge" /> > <a class="cancel" href="/cgi-bin/koha/members/pay.pl?borrowernumber=[% borrower.borrowernumber %]">Cancel</a></div> > </form> > [% ELSE %] >diff --git a/members/pay.pl b/members/pay.pl >index 70e45e2..2295061 100755 >--- a/members/pay.pl >+++ b/members/pay.pl >@@ -97,7 +97,7 @@ if ($writeoff_all) { > writeoff_all(@names); > } elsif ($writeoff_item) { > my $accountlines_id = $input->param('accountlines_id'); >- my $amount = $input->param('amountoutstanding'); >+ my $amount = $input->param('amountwrittenoff'); > my $payment_note = $input->param("payment_note"); > > Koha::Account->new( { patron_id => $borrowernumber } )->pay( >-- >2.10.2
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 11210
:
67345
|
67583
|
68754
|
69001
|
69090
|
69420