[Koha-bugs] [Bug 26648] Prevent internal server error if item attached to old checkout has been removed

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Fri Oct 9 22:48:10 CEST 2020


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26648

--- Comment #3 from Caroline Cyr La Rose <caroline.cyr-la-rose at inlibro.com> ---
Created attachment 111435
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=111435&action=edit
Bug 26648: Prevent explosion in notices on missing item

The item accessor in Koha::Old::Checkouts could explode given a checkout
where the item had been deleted.

To test
1/ Edit the issueslip notice to output some item details from the
borrowers old checkouts

[% FOREACH old_checkout IN borrower.old_checkouts %]
  [% IF old_checkout.item %]
    [% old_checkout.item.price %]
  [% END %]
[% END %]

2/ Delete the item associated with an old checkout for a test patron
3/ Print the issueslip for the patron
4/ Note a server side error is triggered
5/ Apply the patch
6/ Print the slip again and note the price details for old checkouts are
now displayed
7/ Signoff

Signed-off-by: Caroline Cyr La Rose <caroline.cyr-la-rose at inlibro.com>

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list