[Bug 33364] New: Stop Holds to Pull report showing items that have been allocated to a recall
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 Bug ID: 33364 Summary: Stop Holds to Pull report showing items that have been allocated to a recall Change sponsored?: --- Product: Koha Version: 22.11 Hardware: All OS: All Status: NEW Severity: minor Priority: P5 - low Component: Hold requests Assignee: koha-bugs@lists.koha-community.org Reporter: aleisha@catalyst.net.nz QA Contact: testopia@bugs.koha-community.org CC: gmcharlt@gmail.com The Holds to Pull report shows an item with a hold if the item is available on the shelf, ready to pull and allocate to the hold. The Holds to Pull should NOT show an item with a hold if that item has already been allocated to a recall (i.e. the recalled item is awaiting pickup and or in transit for a patron). To reproduce: 1. Enable UseRecalls and set the recalls-related circulation rules 2. Check out an item to Patron A 3. Place a hold on the item for Patron B 4. Log into the OPAC as Patron C and search for the item. Place a recall on the item. 5. Go back to the staff interface. Go to Circulation -> Holds to pull 6. Confirm the item shows in the Holds to pull table, with the hold for Patron B 7. Check in the item and confirm the recall as waiting 8. Go back to the Holds to pull page. You could manually regenerate the page but running the cronjob in the terminal misc/cronjobs/holds/build_holds_queue.pl 9. Notice that even though the item is allocated for a recall, the hold is showing. It should not be showing in this page. -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 Aleisha Amohia <aleisha@catalyst.net.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED Assignee|koha-bugs@lists.koha-commun |wainuiwitikapark@catalyst.n |ity.org |et.nz Change sponsored?|--- |Sponsored -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 Aleisha Amohia <aleisha@catalyst.net.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Patch complexity|--- |Small patch Status|ASSIGNED |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 --- Comment #1 from Aleisha Amohia <aleisha@catalyst.net.nz> --- Created attachment 149741 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=149741&action=edit Bug 33364: Prevent Holds to Pull from including items with pending recalls This patch changes the check for pending recalls to include items in transit, as well as items awaiting pickup, to fill a recall request. It then ensures the Holds to Pull report excludes items that have pending recalls. To test: 1. Enable UseRecalls and set the recalls-related circulation rules 2. Check out an item to Patron A 3. Place a hold on the item for Patron B 4. Log into the OPAC as Patron C and search for the item. Place a recall on the item. 5. Go back to the staff interface. Go to Circulation -> Holds to pull 6. Confirm the item shows in the Holds to pull table, with the hold for Patron B 7. Check in the item and confirm the recall as waiting 8. Go back to the Holds to pull page. You may need to manually regenerate the page by running the cronjob in the terminal misc/cronjobs/holds/build_holds_queue.pl 9. Notice that even though the item is allocated for a recall, the hold is showing. It should not be showing in this page. 10. Apply the patch and refresh the page 11. The item allocated to a recall should no longer be showing in the Holds to pull report 12. Go to the record detail page and go to the Recalls tab 13. Revert the recall from its waiting status 14. The record will now show on the Holds to pull page 15. Go to the Circulation -> Check in page 16. Go to the menu in the top-right of the page and click Set library 17. Change your library to a different one 18. Check in the item to confirm the recall as waiting and trigger a transfer 19. Go back to the Holds to pull page, regenerate if needed 20. The item should no longer show on the Holds to pull report 21. Confirm tests pass t/db_dependent/Koha/Item.t Sponsored-by: Auckland University of Technology -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 Aleisha Amohia <aleisha@catalyst.net.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|wainuiwitikapark@catalyst.n |aleisha@catalyst.net.nz |et.nz | Text to go in the| |This patch changes the release notes| |check for pending recalls | |to include items in | |transit, as well as items | |awaiting pickup, to fill a | |recall request. | | | |It then | |ensures the Holds to Pull | |report excludes items that | |have pending recalls. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 --- Comment #2 from Aleisha Amohia <aleisha@catalyst.net.nz> --- Created attachment 149742 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=149742&action=edit Bug 33364: [22.05] Prevent Holds to Pull from including items with pending recalls This patch changes the check for pending recalls to include items in transit, as well as items awaiting pickup, to fill a recall request. It then ensures the Holds to Pull report excludes items that have pending recalls. To test: 1. Enable UseRecalls and set the recalls-related circulation rules 2. Check out an item to Patron A 3. Place a hold on the item for Patron B 4. Log into the OPAC as Patron C and search for the item. Place a recall on the item. 5. Go back to the staff interface. Go to Circulation -> Holds to pull 6. Confirm the item shows in the Holds to pull table, with the hold for Patron B 7. Check in the item and confirm the recall as waiting 8. Go back to the Holds to pull page. You may need to manually regenerate the page by running the cronjob in the terminal misc/cronjobs/holds/build_holds_queue.pl 9. Notice that even though the item is allocated for a recall, the hold is showing. It should not be showing in this page. 10. Apply the patch and refresh the page 11. The item allocated to a recall should no longer be showing in the Holds to pull report 12. Go to the record detail page and go to the Recalls tab 13. Revert the recall from its waiting status 14. The record will now show on the Holds to pull page 15. Go to the Circulation -> Check in page 16. Go to the menu in the top-right of the page and click Set library 17. Change your library to a different one 18. Check in the item to confirm the recall as waiting and trigger a transfer 19. Go back to the Holds to pull page, regenerate if needed 20. The item should no longer show on the Holds to pull report 21. Confirm tests pass t/db_dependent/Koha/Item.t Sponsored-by: Auckland University of Technology -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 Aleisha Amohia <aleisha@catalyst.net.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #149742|0 |1 is obsolete| | --- Comment #3 from Aleisha Amohia <aleisha@catalyst.net.nz> --- Created attachment 149784 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=149784&action=edit Bug 33364: [22.05] Prevent Holds to Pull from including items with pending recalls This patch changes the check for pending recalls to include items in transit, as well as items awaiting pickup, to fill a recall request. It then ensures the Holds to Pull report excludes items that have pending recalls. To test: 1. Enable UseRecalls and set the recalls-related circulation rules 2. Check out an item to Patron A 3. Place a hold on the item for Patron B 4. Log into the OPAC as Patron C and search for the item. Place a recall on the item. 5. Go back to the staff interface. Go to Circulation -> Holds to pull 6. Confirm the item shows in the Holds to pull table, with the hold for Patron B 7. Check in the item and confirm the recall as waiting 8. Go back to the Holds to pull page. You may need to manually regenerate the page by running the cronjob in the terminal misc/cronjobs/holds/build_holds_queue.pl 9. Notice that even though the item is allocated for a recall, the hold is showing. It should not be showing in this page. 10. Apply the patch and refresh the page 11. The item allocated to a recall should no longer be showing in the Holds to pull report 12. Go to the record detail page and go to the Recalls tab 13. Revert the recall from its waiting status 14. The record will now show on the Holds to pull page 15. Go to the Circulation -> Check in page 16. Go to the menu in the top-right of the page and click Set library 17. Change your library to a different one 18. Check in the item to confirm the recall as waiting and trigger a transfer 19. Go back to the Holds to pull page, regenerate if needed 20. The item should no longer show on the Holds to pull report 21. Confirm tests pass t/db_dependent/Koha/Item.t Sponsored-by: Auckland University of Technology -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 Sam Lau <samalau@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |samalau@gmail.com Status|Needs Signoff |Patch doesn't apply -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 Aleisha Amohia <aleisha@catalyst.net.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Patch doesn't apply |Needs Signoff --- Comment #4 from Aleisha Amohia <aleisha@catalyst.net.nz> --- I'm not sure why this was set to Patch doesn't apply - the first patch applies cleanly on upstream and 22.11, and the second patch applies cleanly on 22.05. This cannot be tested on a sandbox. Please make sure you do not apply the second patch if testing on 22.11 and higher, and only apply the second patch if testing on 22.05. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Version|22.11 |master -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 --- Comment #5 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Hi Sam, if you want to try again: git bz apply ... Apply? [(y)es, (n)o, (i)nteractive] i Then comment out the second patch by removing the # so it won't be applied. The other option that works here: git bz apply ... Apply? [(y)es, (n)o, (i)nteractive] i git bz apply --skip This will also keep the second patch from being applied. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #149784|0 |1 is obsolete| | --- Comment #6 from David Nind <david@davidnind.com> --- Created attachment 155767 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=155767&action=edit Bug 33364: [22.05] Prevent Holds to Pull from including items with pending recalls This patch changes the check for pending recalls to include items in transit, as well as items awaiting pickup, to fill a recall request. It then ensures the Holds to Pull report excludes items that have pending recalls. To test: 1. Enable UseRecalls and set the recalls-related circulation rules 2. Check out an item to Patron A 3. Place a hold on the item for Patron B 4. Log into the OPAC as Patron C and search for the item. Place a recall on the item. 5. Go back to the staff interface. Go to Circulation -> Holds to pull 6. Confirm the item shows in the Holds to pull table, with the hold for Patron B 7. Check in the item and confirm the recall as waiting 8. Go back to the Holds to pull page. You may need to manually regenerate the page by running the cronjob in the terminal misc/cronjobs/holds/build_holds_queue.pl 9. Notice that even though the item is allocated for a recall, the hold is showing. It should not be showing in this page. 10. Apply the patch and refresh the page 11. The item allocated to a recall should no longer be showing in the Holds to pull report 12. Go to the record detail page and go to the Recalls tab 13. Revert the recall from its waiting status 14. The record will now show on the Holds to pull page 15. Go to the Circulation -> Check in page 16. Go to the menu in the top-right of the page and click Set library 17. Change your library to a different one 18. Check in the item to confirm the recall as waiting and trigger a transfer 19. Go back to the Holds to pull page, regenerate if needed 20. The item should no longer show on the Holds to pull report 21. Confirm tests pass t/db_dependent/Koha/Item.t Sponsored-by: Auckland University of Technology Signed-off-by: David Nind <david@davidnind.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |david@davidnind.com --- Comment #7 from David Nind <david@davidnind.com> --- The 22.05 patch works as per the test plan, and I've signed it off. I haven't signed off the patch for master, as it doesn't seem to work for me: - Step 11 - No change noted after applying the patch, restart_all, refreshing browser, etc. It is still showing on the holds to pull list for Patron B (step 2). Tested using koha-testing-docker (KTD). (For 22.05 - checked out 22.05 branch, for KTD changed .env so that KOHA_IMAGE=22.05, then ktd pull. Accessed KTD using ktd --root --shell) -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Failed QA --- Comment #8 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Hi Aleisha, can you please check David's comment on the patch for master? In reply to David Nind from comment #7)
The 22.05 patch works as per the test plan, and I've signed it off.
I haven't signed off the patch for master, as it doesn't seem to work for me: - Step 11 - No change noted after applying the patch, restart_all, refreshing browser, etc. It is still showing on the holds to pull list for Patron B (step 2).
Tested using koha-testing-docker (KTD). (For 22.05 - checked out 22.05 branch, for KTD changed .env so that KOHA_IMAGE=22.05, then ktd pull. Accessed KTD using ktd --root --shell)
-- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 Aleisha Amohia <aleisha@catalyst.net.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |Needs Signoff --- Comment #9 from Aleisha Amohia <aleisha@catalyst.net.nz> --- The patch applies and works for me. You may find it easier to test using a record with only 1 item. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 --- Comment #10 from David Nind <david@davidnind.com> --- (In reply to Aleisha Amohia from comment #9)
The patch applies and works for me.
You may find it easier to test using a record with only 1 item.
I had another go at testing, but I'm not sure I'm getting it right. Will leave for someone else to test (or I'll try it fresh tomorrow!). 1. If I use a record with one item, for step 6 there is nothing in the holds to pull queue (even after running the cronjob). 2. If I use a record with two or more items (for simplicity, items are all in the same library), it appears on the holds to pull list both before and after the patch is applied - this makes sense to me, as there is more than one item available - both for a hold and the recall. (steps 9 and 11) 3. My recall rules: - Recalls allowed (total): 5 - Recalls per record (count): 5 - On shelf recalls allowed: If any unavailable - Recall due date interval (day): 5 - Recall overdue fine amount: 5.00 - Recall pickup period (day): 5 4. Patrons used: I changed three patrons so that they are all in the same library (Centerville). 5. The tests fail after the patch for master was applied: prove t/db_dependent/Koha/Item.t t/db_dependent/Koha/Item.t .. 22/30 # Looks like you planned 23 tests but ran 24. t/db_dependent/Koha/Item.t .. 25/30 # Failed test 'Recalls tests' # at t/db_dependent/Koha/Item.t line 2122. t/db_dependent/Koha/Item.t .. 28/30 # Looks like you failed 1 test of 30. t/db_dependent/Koha/Item.t .. Dubious, test returned 1 (wstat 256, 0x100) Failed 1/30 subtests Test Summary Report ------------------- t/db_dependent/Koha/Item.t (Wstat: 256 Tests: 30 Failed: 1) Failed test: 25 Non-zero exit status: 1 Files=1, Tests=30, 13 wallclock secs ( 0.04 usr 0.02 sys + 8.30 cusr 3.56 csys = 11.92 CPU) Result: FAIL -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Failed QA --- Comment #11 from David Nind <david@davidnind.com> --- The patch for master still applies, however the tests are still failing. I haven't fully re-tested the 22.05 and master patches yet - see comment #10 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 Aleisha Amohia <aleisha@catalyst.net.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 Aleisha Amohia <aleisha@catalyst.net.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #149741|0 |1 is obsolete| | --- Comment #12 from Aleisha Amohia <aleisha@catalyst.net.nz> --- Created attachment 172054 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=172054&action=edit Bug 33364: Prevent Holds to Pull from including items with pending recalls This patch changes the check for pending recalls to include items in transit, as well as items awaiting pickup, to fill a recall request. It then ensures the Holds to Pull report excludes items that have pending recalls. To test: 1. Enable UseRecalls and set the recalls-related circulation rules 2. Check out an item to Patron A 3. Place a hold on the item for Patron B 4. Log into the OPAC as Patron C and search for the item. Place a recall on the item. 5. Go back to the staff interface. Go to Circulation -> Holds to pull 6. Confirm the item shows in the Holds to pull table, with the hold for Patron B 7. Check in the item and confirm the recall as waiting 8. Go back to the Holds to pull page. You may need to manually regenerate the page by running the cronjob in the terminal misc/cronjobs/holds/build_holds_queue.pl 9. Notice that even though the item is allocated for a recall, the hold is showing. It should not be showing in this page. 10. Apply the patch and refresh the page 11. The item allocated to a recall should no longer be showing in the Holds to pull report 12. Go to the record detail page and go to the Recalls tab 13. Revert the recall from its waiting status 14. The record will now show on the Holds to pull page 15. Go to the Circulation -> Check in page 16. Go to the menu in the top-right of the page and click Set library 17. Change your library to a different one 18. Check in the item to confirm the recall as waiting and trigger a transfer 19. Go back to the Holds to pull page, regenerate if needed 20. The item should no longer show on the Holds to pull report 21. Confirm tests pass t/db_dependent/Koha/Item.t Sponsored-by: Auckland University of Technology -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 Owen Leonard <oleonard@myacpl.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 Owen Leonard <oleonard@myacpl.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #172054|0 |1 is obsolete| | --- Comment #13 from Owen Leonard <oleonard@myacpl.org> --- Created attachment 175080 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=175080&action=edit Bug 33364: Prevent Holds to Pull from including items with pending recalls This patch changes the check for pending recalls to include items in transit, as well as items awaiting pickup, to fill a recall request. It then ensures the Holds to Pull report excludes items that have pending recalls. To test: 1. Enable UseRecalls and set the recalls-related circulation rules 2. Check out an item to Patron A 3. Place a hold on the item for Patron B 4. Log into the OPAC as Patron C and search for the item. Place a recall on the item. 5. Go back to the staff interface. Go to Circulation -> Holds to pull 6. Confirm the item shows in the Holds to pull table, with the hold for Patron B 7. Check in the item and confirm the recall as waiting 8. Go back to the Holds to pull page. You may need to manually regenerate the page by running the cronjob in the terminal misc/cronjobs/holds/build_holds_queue.pl 9. Notice that even though the item is allocated for a recall, the hold is showing. It should not be showing in this page. 10. Apply the patch and refresh the page 11. The item allocated to a recall should no longer be showing in the Holds to pull report 12. Go to the record detail page and go to the Recalls tab 13. Revert the recall from its waiting status 14. The record will now show on the Holds to pull page 15. Go to the Circulation -> Check in page 16. Go to the menu in the top-right of the page and click Set library 17. Change your library to a different one 18. Check in the item to confirm the recall as waiting and trigger a transfer 19. Go back to the Holds to pull page, regenerate if needed 20. The item should no longer show on the Holds to pull report 21. Confirm tests pass t/db_dependent/Koha/Item.t Sponsored-by: Auckland University of Technology Signed-off-by: Owen Leonard <oleonard@myacpl.org> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Text to go in the|This patch changes the |This fixes the "Holds to release notes|check for pending recalls |pull" circulation report to |to include items in |exclude items that have |transit, as well as items |pending recalls (recalled |awaiting pickup, to fill a |items waiting for pickup or |recall request. |in transit for a patron). | | |It then | |ensures the Holds to Pull | |report excludes items that | |have pending recalls. | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |m.de.rooy@rijksmuseum.nl --- Comment #14 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- @@ -1227,7 +1227,7 @@ sub has_pending_recall { return Koha::Recalls->search( { item_id => $self->itemnumber, - status => 'waiting', + status => [ 'waiting', 'in_transit' ], Could you please explain why a recall is named pending, when it is waiting or in transit? Looks like inconsistent naming? Since a pending hold is a hold that is NOT waiting or in transit. Actually it also looks at tmp_holdsqueue (and that table depends on a pref too). -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 --- Comment #15 from Aleisha Amohia <aleisha@catalyst.net.nz> --- (In reply to Marcel de Rooy from comment #14)
@@ -1227,7 +1227,7 @@ sub has_pending_recall { return Koha::Recalls->search( { item_id => $self->itemnumber, - status => 'waiting', + status => [ 'waiting', 'in_transit' ],
Could you please explain why a recall is named pending, when it is waiting or in transit? Looks like inconsistent naming? Since a pending hold is a hold that is NOT waiting or in transit. Actually it also looks at tmp_holdsqueue (and that table depends on a pref too).
Because at this stage, the item has already been allocated to the recall. It is in transit to the library where it would be picked up by the patron who requested it. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 --- Comment #16 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- (In reply to Aleisha Amohia from comment #15)
(In reply to Marcel de Rooy from comment #14)
@@ -1227,7 +1227,7 @@ sub has_pending_recall { return Koha::Recalls->search( { item_id => $self->itemnumber, - status => 'waiting', + status => [ 'waiting', 'in_transit' ],
Could you please explain why a recall is named pending, when it is waiting or in transit? Looks like inconsistent naming? Since a pending hold is a hold that is NOT waiting or in transit. Actually it also looks at tmp_holdsqueue (and that table depends on a pref too).
Because at this stage, the item has already been allocated to the recall. It is in transit to the library where it would be picked up by the patron who requested it.
I think that's what Marcel meant, that "pending" for holds means NOT allocated. I haven't verified that in code, but I believe in the interface that is indeed the case. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 --- Comment #17 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- (In reply to Katrin Fischer from comment #16)
(In reply to Aleisha Amohia from comment #15)
(In reply to Marcel de Rooy from comment #14)
@@ -1227,7 +1227,7 @@ sub has_pending_recall { return Koha::Recalls->search( { item_id => $self->itemnumber, - status => 'waiting', + status => [ 'waiting', 'in_transit' ],
Could you please explain why a recall is named pending, when it is waiting or in transit? Looks like inconsistent naming? Since a pending hold is a hold that is NOT waiting or in transit. Actually it also looks at tmp_holdsqueue (and that table depends on a pref too).
Because at this stage, the item has already been allocated to the recall. It is in transit to the library where it would be picked up by the patron who requested it.
I think that's what Marcel meant, that "pending" for holds means NOT allocated. I haven't verified that in code, but I believe in the interface that is indeed the case.
Right -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 --- Comment #18 from Aleisha Amohia <aleisha@catalyst.net.nz> --- Okay, so the request is to rename that subroutine? -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 --- Comment #19 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- (In reply to Aleisha Amohia from comment #18)
Okay, so the request is to rename that subroutine?
See previous comment. Please clarify. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 Martin Renvoize (ashimema) <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |martin.renvoize@ptfs-europe | |.com --- Comment #20 from Martin Renvoize (ashimema) <martin.renvoize@ptfs-europe.com> --- I've not dug deep into the code here.. but it feels like it should be applying to 'get_items_that_can_fill' rather than filtering after? -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Failed QA --- Comment #21 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- (In reply to Martin Renvoize (ashimema) from comment #20)
I've not dug deep into the code here.. but it feels like it should be applying to 'get_items_that_can_fill' rather than filtering after?
Sounds like a good question. Feedback needed. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 Aleisha Amohia <aleisha@catalyst.net.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |ASSIGNED --- Comment #22 from Aleisha Amohia <aleisha@catalyst.net.nz> --- (In reply to Marcel de Rooy from comment #19)
(In reply to Aleisha Amohia from comment #18)
Okay, so the request is to rename that subroutine?
See previous comment. Please clarify.
In this case, a pending recall is one where an item has been allocated, but the request has not been filled - the item is not yet with the patron. (In reply to Marcel de Rooy from comment #21)
(In reply to Martin Renvoize (ashimema) from comment #20)
I've not dug deep into the code here.. but it feels like it should be applying to 'get_items_that_can_fill' rather than filtering after?
Sounds like a good question. Feedback needed.
That's a good idea. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 Aleisha Amohia <aleisha@catalyst.net.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 Aleisha Amohia <aleisha@catalyst.net.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #155767|0 |1 is obsolete| | Attachment #175080|0 |1 is obsolete| | --- Comment #23 from Aleisha Amohia <aleisha@catalyst.net.nz> --- Created attachment 186351 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=186351&action=edit Bug 33364: Prevent Holds to Pull from including items with pending recalls This patch checks for waiting or in_transit items allocated to recalls, and excludes them from the Holds to Pull report. To test: 1. Enable UseRecalls and set the recalls-related circulation rules 2. Check out an item to Patron A 3. Place a hold on the item for Patron B 4. Log into the OPAC as Patron C and search for the item. Place a recall on the item. 5. Go back to the staff interface. Go to Circulation -> Holds to pull 6. Confirm the item shows in the Holds to pull table, with the hold for Patron B 7. Check in the item and confirm the recall as waiting 8. Go back to the Holds to pull page. You may need to manually regenerate the page by running the cronjob in the terminal misc/cronjobs/holds/build_holds_queue.pl 9. Notice that even though the item is allocated for a recall, the hold is showing. It should not be showing in this page. 10. Apply the patch and refresh the page 11. The item allocated to a recall should no longer be showing in the Holds to pull report 12. Go to the record detail page and go to the Recalls tab 13. Revert the recall from its waiting status 14. The record will now show on the Holds to pull page 15. Go to the Circulation -> Check in page 16. Go to the menu in the top-right of the page and click Set library 17. Change your library to a different one 18. Check in the item to confirm the recall as waiting and trigger a transfer 19. Go back to the Holds to pull page, regenerate if needed 20. The item should no longer show on the Holds to pull report 21. Confirm tests pass t/db_dependent/Koha/Holds.t Sponsored-by: Catalyst IT -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|Stop Holds to Pull report |Stop holds to pull report |showing items that have |showing items that have |been allocated to a recall |been allocated to a recall Status|Needs Signoff |Failed QA --- Comment #24 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- 1) QA checks - pass! 2) Code review - nothing spotted - Logical change - Includes unit tests. 3) Testing The main problem here is that I was not able to reproduce the problem in order to check the patch works as it should. a) Confusion about reports This bit is a bit confusing: 8. Go back to the Holds to pull page. You may need to manually regenerate the page by running the cronjob in the terminal misc/cronjobs/holds/build_holds_queue.pl The holds to pull page doesn't depend on the cron, only the holds queue does. I've rebuilt the holds queue anyway and checked both pages, but I cannot get the waiting recall to show up in either one before applying the patch. My item has the status: Waiting recall at Centerville since 01/26/2026 Centerville is pick-up location. I then reverted the waiting status and it still would not show up on either page, but on recalls to pull. Can you please check what I might have missed or if this was maybe fixed in another way already? -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 Aleisha Amohia <aleisha@catalyst.net.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |Needs Signoff Comma delimited| |Catalyst IT list of Sponsors| | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 Aleisha Amohia <aleisha@catalyst.net.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #186351|0 |1 is obsolete| | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 --- Comment #25 from Aleisha Amohia <aleisha@catalyst.net.nz> --- Created attachment 200615 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=200615&action=edit Bug 33364: Prevent Holds to Pull from including items with pending recalls This patch checks for waiting or in_transit items allocated to recalls, and excludes them from the Holds to Pull report. To test: 1. Enable UseRecalls and set the recalls-related circulation rules 2. Check out an item to Patron A 3. Place an item-level hold on the item for Patron B 4. Log into the OPAC as Patron C and search for the item. Place an item-level recall on the item. 5. Go back to the staff interface and check in the item. This should prompt a pop-up to confirm the recall as waiting. Confirm the recall as waiting. 6. Go to Circulation -> Holds to pull. 7. Notice that even though the item is allocated for a recall, the hold is showing. It should not be showing in this page. 8. Apply the patch, restart services and refresh the page 9. The item allocated to a recall should no longer be showing in the Holds to pull report 10. Go to the record detail page and go to the Recalls tab 11. Revert the recall from its waiting status 12. Go back to the Holds to pull page. The record will now show for the hold. 13. Go to the Circulation -> Check in page 14. Go to the menu in the top-right of the page and click Set library 15. Change your library to a different one 16. Check in the item to confirm the recall as waiting and trigger a transfer 17. Go back to the Holds to pull page 19. The item should no longer show on the Holds to pull report 20. Confirm tests pass t/db_dependent/Koha/Holds.t Sponsored-by: Catalyst IT -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 --- Comment #26 from Aleisha Amohia <aleisha@catalyst.net.nz> --- (In reply to Katrin Fischer from comment #24)
Can you please check what I might have missed or if this was maybe fixed in another way already?
You were right, the test plan was quite wrong! Have fixed up. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #200615|0 |1 is obsolete| | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33364 --- Comment #27 from David Nind <david@davidnind.com> --- Created attachment 200681 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=200681&action=edit Bug 33364: Prevent Holds to Pull from including items with pending recalls This patch checks for waiting or in_transit items allocated to recalls, and excludes them from the Holds to Pull report. To test: 1. Enable UseRecalls and set the recalls-related circulation rules 2. Check out an item to Patron A 3. Place an item-level hold on the item for Patron B 4. Log into the OPAC as Patron C and search for the item. Place an item-level recall on the item. 5. Go back to the staff interface and check in the item. This should prompt a pop-up to confirm the recall as waiting. Confirm the recall as waiting. 6. Go to Circulation -> Holds to pull. 7. Notice that even though the item is allocated for a recall, the hold is showing. It should not be showing in this page. 8. Apply the patch, restart services and refresh the page 9. The item allocated to a recall should no longer be showing in the Holds to pull report 10. Go to the record detail page and go to the Recalls tab 11. Revert the recall from its waiting status 12. Go back to the Holds to pull page. The record will now show for the hold. 13. Go to the Circulation -> Check in page 14. Go to the menu in the top-right of the page and click Set library 15. Change your library to a different one 16. Check in the item to confirm the recall as waiting and trigger a transfer 17. Go back to the Holds to pull page 19. The item should no longer show on the Holds to pull report 20. Confirm tests pass t/db_dependent/Koha/Holds.t Sponsored-by: Catalyst IT Signed-off-by: David Nind <david@davidnind.com> -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org