Bug 21168 - Error on circ/returns.pl after deleting checked-in item
Summary: Error on circ/returns.pl after deleting checked-in item
Status: RESOLVED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Circulation (show other bugs)
Version: master
Hardware: All All
: P5 - low normal (vote)
Assignee: Jonathan Druart
QA Contact: Testopia
URL:
Whiteboard:
Keywords:
Depends on: 18276
Blocks:
  Show dependency treegraph
 
Reported: 2018-08-07 15:30 UTC by Andrew
Modified: 2018-09-24 07:05 UTC (History)
7 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Trivial patch
Bot Control: ---
When did the bot last check this:
Who signed the patch off:
Text to go in the release notes:


Attachments
Bug 21168: Handle deleted checked-in items on checking in (1.40 KB, patch)
2018-08-10 20:05 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 21168: Handle deleted checked-in items on checking in (1.45 KB, patch)
2018-08-24 17:36 UTC, Tomás Cohen Arazi
Details | Diff | Splinter Review
Bug 21168: Handle deleted checked-in items on checking in (1.44 KB, patch)
2018-08-26 16:27 UTC, Katrin Fischer
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Andrew 2018-08-07 15:30:30 UTC
circ/returns.pl generates a server error when attempting to checkin an item while the list of previously-returned items contains an item that has been deleted. Error text: Can't call method "biblio" on an undefined value at /usr/share/koha/intranet/cgi-bin/circ/returns.pl line 606.

To test:
- checkout two items
- checkin item1
- on a separate tab, delete item1
- on the original tab (which still shows item1 in the list of Checked-In Items), attempt to check in item2
- error appears

item2 will have been successfully returned, despite the error, but no confirmation of this is given.
Comment 1 Jonathan Druart 2018-08-10 20:05:25 UTC
Created attachment 77715 [details] [review]
Bug 21168: Handle deleted checked-in items on checking in

circ/returns.pl generates a server error when attempting to checkin an item while
the list of previously-returned items contains an item that has been deleted.
Error text: Can't call method "biblio" on an undefined value at /usr/share/koha/intranet/cgi-bin/circ/returns.pl line 606.

Test plan:
- checkout two items
- checkin item1
- on a separate tab, delete item1
- on the original tab (which still shows item1 in the list of Checked-In Items), attempt to check in item2
=> No error appears
Comment 2 Jonathan Druart 2018-08-10 20:06:36 UTC
Caused by:
  commit 6eade474ed3a84a5ba372a26ac27bf9fb4bd2299
  Bug 18276: Remove GetBiblioFromItemNumber - Easy ones
Comment 3 Tomás Cohen Arazi 2018-08-24 17:36:32 UTC
Created attachment 78146 [details] [review]
Bug 21168: Handle deleted checked-in items on checking in

circ/returns.pl generates a server error when attempting to checkin an item while
the list of previously-returned items contains an item that has been deleted.
Error text: Can't call method "biblio" on an undefined value at /usr/share/koha/intranet/cgi-bin/circ/returns.pl line 606.

Test plan:
- checkout two items
- checkin item1
- on a separate tab, delete item1
- on the original tab (which still shows item1 in the list of Checked-In Items), attempt to check in item2
=> No error appears

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Comment 4 Katrin Fischer 2018-08-26 16:27:15 UTC
Created attachment 78172 [details] [review]
Bug 21168: Handle deleted checked-in items on checking in

circ/returns.pl generates a server error when attempting to checkin an item while
the list of previously-returned items contains an item that has been deleted.
Error text: Can't call method "biblio" on an undefined value at /usr/share/koha/intranet/cgi-bin/circ/returns.pl line 606.

Test plan:
- checkout two items
- checkin item1
- on a separate tab, delete item1
- on the original tab (which still shows item1 in the list of Checked-In Items), attempt to check in item2
=> No error appears

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Comment 5 Katrin Fischer 2018-08-27 12:43:36 UTC
Sorry, forgot the sign-off line. RM, would you make an exception and add it before push?
Comment 6 Nick Clemens 2018-08-30 14:11:48 UTC
Awesome work all!

Pushed to master for 18.11
Comment 7 Martin Renvoize 2018-09-05 09:42:44 UTC
Pushed to 18.05.x for 18.05.04
Comment 8 Fridolin SOMERS 2018-09-24 07:05:34 UTC
Pushed to 17.11.x for 17.11.10