This routine is just a SQL fetch of the issue row for an itemnumber - we should use Koha::Checkouts->find({itemnumber=>$itemnumber}) instead
Created attachment 130141 [details] [review] Bug 30016: Remove GetOpenIssue subroutine This patch adjusts the code that uses GetOpenIssue to use/find a Koha::Checkout object instead To test: 1 - Add a course to course reserves 2 - Create an item with barcode TESTKOC 3 - Add the item to a course 4 - Checkout the item 5 - View course details on stff and opac and confirm item shows as checked out and due date displays 6 - prove t/db_dependent/Circulation/issue.t t/db_dependent/Circulation.t t/db_dependent/CourseReserves.t 7 - Browse to Circulation->Upload offline circulation 8 - Upload a file to return the item: https://wiki.koha-community.org/wiki/Koha_offline_circulation_file_format 9 - Confirm item is returned
Created attachment 130142 [details] Sample koc file
Hi, this looks fine, but I think you meant to use $item->checkout, otherwise it is a DBIC row you're dealing with?
Created attachment 130497 [details] [review] Bug 30016: Remove GetOpenIssue subroutine This patch adjusts the code that uses GetOpenIssue to use/find a Koha::Checkout object instead To test: 1 - Add a course to course reserves 2 - Create an item with barcode TESTKOC 3 - Add the item to a course 4 - Checkout the item 5 - View course details on stff and opac and confirm item shows as checked out and due date displays 6 - prove t/db_dependent/Circulation/issue.t t/db_dependent/Circulation.t t/db_dependent/CourseReserves.t 7 - Browse to Circulation->Upload offline circulation 8 - Upload a file to return the item: https://wiki.koha-community.org/wiki/Koha_offline_circulation_file_format 9 - Confirm item is returned
Should we move this back to "Needs Sign-off"?
Patch no longer applies 8-(.. Applying: Bug 30016: Remove GetOpenIssue subroutine Using index info to reconstruct a base tree... M C4/Circulation.pm M offline_circ/process_koc.pl M t/db_dependent/Circulation/issue.t Falling back to patching base and 3-way merge... Auto-merging t/db_dependent/Circulation/issue.t CONFLICT (content): Merge conflict in t/db_dependent/Circulation/issue.t Auto-merging offline_circ/process_koc.pl Auto-merging C4/Circulation.pm error: Failed to merge in the changes. Patch failed at 0001 Bug 30016: Remove GetOpenIssue subroutine
Created attachment 139400 [details] [review] Bug 30016: Remove GetOpenIssue subroutine This patch adjusts the code that uses GetOpenIssue to use/find a Koha::Checkout object instead To test: 1 - Add a course to course reserves 2 - Create an item with barcode TESTKOC 3 - Add the item to a course 4 - Checkout the item 5 - View course details on stff and opac and confirm item shows as checked out and due date displays 6 - prove t/db_dependent/Circulation/issue.t t/db_dependent/Circulation.t t/db_dependent/CourseReserves.t 7 - Browse to Circulation->Upload offline circulation 8 - Upload a file to return the item: https://wiki.koha-community.org/wiki/Koha_offline_circulation_file_format 9 - Confirm item is returned
Created attachment 139451 [details] [review] Bug 30016: Remove GetOpenIssue subroutine This patch adjusts the code that uses GetOpenIssue to use/find a Koha::Checkout object instead To test: 1 - Add a course to course reserves 2 - Create an item with barcode TESTKOC 3 - Add the item to a course 4 - Checkout the item 5 - View course details on stff and opac and confirm item shows as checked out and due date displays 6 - prove t/db_dependent/Circulation/issue.t t/db_dependent/Circulation.t t/db_dependent/CourseReserves.t 7 - Browse to Circulation->Upload offline circulation 8 - Upload a file to return the item: https://wiki.koha-community.org/wiki/Koha_offline_circulation_file_format 9 - Confirm item is returned Signed-off-by: David Nind <david@davidnind.com>
Created attachment 139899 [details] [review] Bug 30016: Remove GetOpenIssue subroutine This patch adjusts the code that uses GetOpenIssue to use/find a Koha::Checkout object instead To test: 1 - Add a course to course reserves 2 - Create an item with barcode TESTKOC 3 - Add the item to a course 4 - Checkout the item 5 - View course details on stff and opac and confirm item shows as checked out and due date displays 6 - prove t/db_dependent/Circulation/issue.t t/db_dependent/Circulation.t t/db_dependent/CourseReserves.t 7 - Browse to Circulation->Upload offline circulation 8 - Upload a file to return the item: https://wiki.koha-community.org/wiki/Koha_offline_circulation_file_format 9 - Confirm item is returned Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Pushed to master for 22.11. Nice work everyone, thanks!