Summary: | delete_items.pl missing include | ||
---|---|---|---|
Product: | Koha | Reporter: | Tomás Cohen Arazi (tcohen) <tomascohen> |
Component: | Command-line Utilities | Assignee: | Tomás Cohen Arazi (tcohen) <tomascohen> |
Status: | CLOSED FIXED | QA Contact: | Testopia <testopia> |
Severity: | major | ||
Priority: | P5 - low | CC: | andrew, fridolin.somers, jonathan.druart, kyle, lucas, robin |
Version: | Main | ||
Hardware: | All | ||
OS: | All | ||
See Also: | https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28255 | ||
Change sponsored?: | --- | Patch complexity: | Trivial patch |
Documentation contact: | Documentation submission: | ||
Text to go in the release notes: | Version(s) released in: |
22.05.00,21.11.02
|
|
Circulation function: | |||
Bug Depends on: | 23463 | ||
Bug Blocks: | 29788 | ||
Attachments: |
Bug 29794: Add missing include in delete_items.pl
Bug 29794: (follow-up) Add license Bug 29794: Add missing include in delete_items.pl Bug 29794: (follow-up) Add license Bug 29794: (follow-up) Add license |
Description
Tomás Cohen Arazi (tcohen)
2022-01-04 19:50:27 UTC
Created attachment 129011 [details] [review] Bug 29794: Add missing include in delete_items.pl This patch adds a missing include so the script is no longer broken. To test: 1. Choose an item that is checked out and copy its barcode 2. Run: $ kshell k$ perl misc/cronjobs/delete_items.pl --verbose \ --where "barcode='39999000010831'" => FAIL: It explodes with: Can't locate object method "find" via package "Koha::Items"... 3. Apply this patch 4. Repeat 2 => SUCCESS: You get: Where statement: where barcode='39999000010831' Item '549' not deleted: book_on_loan 5. Sign off :-D Created attachment 129012 [details] [review] Bug 29794: (follow-up) Add license Created attachment 129014 [details] [review] Bug 29794: Add missing include in delete_items.pl This patch adds a missing include so the script is no longer broken. To test: 1. Choose an item that is checked out and copy its barcode 2. Run: $ kshell k$ perl misc/cronjobs/delete_items.pl --verbose \ --where "barcode='39999000010831'" => FAIL: It explodes with: Can't locate object method "find" via package "Koha::Items"... 3. Apply this patch 4. Repeat 2 => SUCCESS: You get: Where statement: where barcode='39999000010831' Item '549' not deleted: book_on_loan 5. Sign off :-D Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> Created attachment 129015 [details] [review] Bug 29794: (follow-up) Add license Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> Does nobody use this script? Created attachment 129017 [details] [review] Bug 29794: (follow-up) Add license Signed-off-by: Lucas Gass <lucas@bywatersolutions.com> Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Bug 23463 replaced DelItemCheck() with Koha::Items->find() and $item->safe_delete It should have impact the includes Pushed to master for 22.05, thanks to everybody involved [U+1F984] Pushed to 21.11.x for 21.11.02 I can't recreate this issue on 21.05.x. Following the test plan, I get the correct message of "Item '1' not deleted: book_on_loan" without the patch applied. Not backporting, please request if needed. |