At this time, only payments may be voided. There is no reason to have this limitation. There are situations where a librarian may need to void an accidental writeoff, or perhaps void an automatic credit that was created by Koha. For illustration, this is directly from a partner library: "For example a lost book refund becomes a credit on account. Presently the credit may be applied to a fine for a different item charged to patron. We perform a write off to clear the remaining credit, then add the fine back to the account and give the patron a refund for the lost/refunded amount. Our accounting system ask that we keep the Lost funds/refunds separate from all fines."
*** Bug 19449 has been marked as a duplicate of this bug. ***
Created attachment 75013 [details] [review] Bug 20703: Add ability to void any credit At this time, only payments may be voided. There is no reason to have this limitation. There are situations where a librarian may need to void an accidental writeoff, or perhaps void an automatic credit that was created by Koha. For illustration, this is directly from a partner library: "For example a lost book refund becomes a credit on account. Presently the credit may be applied to a fine for a different item charged to patron. We perform a write off to clear the remaining credit, then add the fine back to the account and give the patron a refund for the lost/refunded amount. Our accounting system ask that we keep the Lost funds/refunds separate from all fines." Test Plan: 1) Create a fine and write it off 2) Note there is no 'void' button for the writeoff 3) Apply this patch 4) Note the buttons now show 5) Test each button on a writeoff
Comment on attachment 75013 [details] [review] Bug 20703: Add ability to void any credit Review of attachment 75013 [details] [review]: ----------------------------------------------------------------- ::: Koha/Account/Line.pm @@ +60,4 @@ > my ($self) = @_; > > # Make sure it is a payment we are voiding > + return unless $self->amount < 0; Much nicer to not be dependent on a particular text. ::: koha-tmpl/intranet-tmpl/prog/en/modules/members/boraccount.tt @@ +77,5 @@ > + [% END %] > + [% IF account.amount < 0 %] > + <a href="boraccount.pl?action=void&accountlines_id=[% account.accountlines_id %]&borrowernumber=[% account.borrowernumber %]" class="btn btn-default btn-xs"><i class="fa fa-ban"></i> Void</a> > + [% END %] > + [% ELSE %] Nice catch on the footerjs already at the top of the file.
Created attachment 75154 [details] [review] Bug 20703: Add ability to void any credit At this time, only payments may be voided. There is no reason to have this limitation. There are situations where a librarian may need to void an accidental writeoff, or perhaps void an automatic credit that was created by Koha. For illustration, this is directly from a partner library: "For example a lost book refund becomes a credit on account. Presently the credit may be applied to a fine for a different item charged to patron. We perform a write off to clear the remaining credit, then add the fine back to the account and give the patron a refund for the lost/refunded amount. Our accounting system ask that we keep the Lost funds/refunds separate from all fines." Test Plan: 1) Create a fine and write it off 2) Note there is no 'void' button for the writeoff 3) Apply this patch 4) Note the buttons now show 5) Test each button on a writeoff Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Kyle, the functionality is ok. Would you agree there could be a confirmation modal as we have in other places?
Created attachment 75468 [details] [review] Bug 20703: Add ability to void any credit At this time, only payments may be voided. There is no reason to have this limitation. There are situations where a librarian may need to void an accidental writeoff, or perhaps void an automatic credit that was created by Koha. For illustration, this is directly from a partner library: "For example a lost book refund becomes a credit on account. Presently the credit may be applied to a fine for a different item charged to patron. We perform a write off to clear the remaining credit, then add the fine back to the account and give the patron a refund for the lost/refunded amount. Our accounting system ask that we keep the Lost funds/refunds separate from all fines." Test Plan: 1) Create a fine and write it off 2) Note there is no 'void' button for the writeoff 3) Apply this patch 4) Note the buttons now show 5) Test each button on a writeoff Signed-off-by: Mark Tompsett <mtompset@hotmail.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
(In reply to Tomás Cohen Arazi from comment #5) > Kyle, the functionality is ok. Would you agree there could be a confirmation > modal as we have in other places? A confirmation modal would be a nice enhancement! Are you able to add that?
Created attachment 75471 [details] [review] Bug 20703: Add confirmation modal when making a credit void Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Created attachment 75472 [details] [review] Bug 20703: Add confirmation modal when making a credit void Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Awesome work all! Pushed to master for 18.11
Enhancement, not backporting to 18.05.x series.