Summary: | Checking in a waiting hold at another branch when HoldsAutoFill is enabled causes errors | ||
---|---|---|---|
Product: | Koha | Reporter: | Nick Clemens (kidclamp) <nick> |
Component: | Hold requests | Assignee: | Jonathan Druart <jonathan.druart> |
Status: | CLOSED FIXED | QA Contact: | Testopia <testopia> |
Severity: | major | ||
Priority: | P5 - low | CC: | gmcharlt, jonathan.druart, kyle, martin.renvoize, victor |
Version: | Main | ||
Hardware: | All | ||
OS: | All | ||
Change sponsored?: | --- | Patch complexity: | --- |
Documentation contact: | Martin Renvoize | Documentation submission: | |
Text to go in the release notes: | Version(s) released in: |
22.05.00,21.11.06,21.05.16
|
|
Circulation function: | |||
Bug Depends on: | 23070 | ||
Bug Blocks: | |||
Attachments: |
Bug 30630: Prevent crash on check-in if HoldsAutoFill is ON
Bug 30630: Prevent crash on check-in if HoldsAutoFill is ON Bug 30630: Prevent crash on check-in if HoldsAutoFill is ON |
Description
Nick Clemens (kidclamp)
2022-04-27 15:28:09 UTC
To recreate: 1 - Enable HoldsAutoFill 2 - Place a title level hold 3 - Check in an item and confirm hold 4 - Switch to another branch 5 - Checkin the item, get an error: Can't call method "biblionumber" on an undefined value at /kohadevbox/koha/C4/Reserves.pm line 1577. at /kohadevbox/koha/C4/Reserves.pm line 1576 6- This causes lingering issues because the hold is now in-transit but has no itemnumber Root seems to be in circ/returns.pl: 477 ModReserveAffect( $reserve->{itemnumber}, $reserve->{borrowernumber}, $diffBranchSend, $reserve->{reserve_ id}, $desk_id ); RevertWaitingStatus has already removed the itemnumber from the hold, passing $itemnumber (from scanned item) should work, as it will reattach the hold to the item yes, *should* :) Created attachment 134203 [details] [review] Bug 30630: Prevent crash on check-in if HoldsAutoFill is ON RevertWaitingStatus has already removed the itemnumber from the hold, passing $itemnumber (from scanned item) should work, as it will reattach the hold to the item Test plan: 1 - Enable HoldsAutoFill 2 - Place a title level hold 3 - Check in an item and confirm hold 4 - Switch to another branch 5 - Checkin the item Without this patch you got Can't call method "biblionumber" on an undefined value at /kohadevbox/koha/C4/Reserves.pm line 1577. at /kohadevbox/koha/C4/Reserves.pm line 1576 With this patch applied the operation succeeds Created attachment 134208 [details] [review] Bug 30630: Prevent crash on check-in if HoldsAutoFill is ON RevertWaitingStatus has already removed the itemnumber from the hold, passing $itemnumber (from scanned item) should work, as it will reattach the hold to the item Test plan: 1 - Enable HoldsAutoFill 2 - Place a title level hold 3 - Check in an item and confirm hold 4 - Switch to another branch 5 - Checkin the item Without this patch you got Can't call method "biblionumber" on an undefined value at /kohadevbox/koha/C4/Reserves.pm line 1577. at /kohadevbox/koha/C4/Reserves.pm line 1576 With this patch applied the operation succeeds Signed-off-by: David Nind <david@davidnind.com> Created attachment 134218 [details] [review] Bug 30630: Prevent crash on check-in if HoldsAutoFill is ON RevertWaitingStatus has already removed the itemnumber from the hold, passing $itemnumber (from scanned item) should work, as it will reattach the hold to the item Test plan: 1 - Enable HoldsAutoFill 2 - Place a title level hold 3 - Check in an item and confirm hold 4 - Switch to another branch 5 - Checkin the item Without this patch you got Can't call method "biblionumber" on an undefined value at /kohadevbox/koha/C4/Reserves.pm line 1577. at /kohadevbox/koha/C4/Reserves.pm line 1576 With this patch applied the operation succeeds Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Pushed to master for 22.05, thanks to everybody involved [U+1F984] Pushed to 21.11.x for 21.11.06 Backported: Pushed to 21.05.x branch for 21.05.16 Bugfix, no workflow of visual changes.. No documentation updates required. |