Bug 31314

Summary: Remove GetItemsInfo from opac-reserve.pl
Product: Koha Reporter: Jonathan Druart <jonathan.druart>
Component: Architecture, internals, and plumbingAssignee: Jonathan Druart <jonathan.druart>
Status: CLOSED FIXED QA Contact: Testopia <testopia>
Severity: enhancement    
Priority: P5 - low CC: nick
Version: unspecified   
Hardware: All   
OS: All   
Change sponsored?: --- Patch complexity: Small patch
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
22.11.00
Bug Depends on: 31306, 31307    
Bug Blocks: 31353, 27272, 30847, 33299    
Attachments: Bug 31314: Remove GetHostItemsInfo and GetItemsInfo from opac-reserve
Bug 31314: Remove GetHostItemsInfo and GetItemsInfo from opac-reserve
Bug 31314: Remove GetHostItemsInfo and GetItemsInfo from opac-reserve
Bug 31314: Remove GetHostItemsInfo and GetItemsInfo from opac-reserve
Bug 31314: (QA follow-up) Search Koha::Items not $biblio->items
Bug 31314: (QA follow-up) Prefetch and make routines use result objects

Description Jonathan Druart 2022-08-08 14:22:53 UTC
Bug 27272 is going to remove C4::Items::GetItemsInfo in favour of Koha::Items->search_ordered.

Here we are going to deal with opac-reserve.pl
Comment 1 Jonathan Druart 2022-08-08 14:51:04 UTC Comment hidden (obsolete)
Comment 2 Jonathan Druart 2022-08-09 07:51:56 UTC Comment hidden (obsolete)
Comment 3 Owen Leonard 2022-08-09 14:19:54 UTC Comment hidden (obsolete)
Comment 4 Katrin Fischer 2022-08-12 15:26:08 UTC
Plan to come back, but removing QA contact to not block!
Comment 5 Nick Clemens 2022-08-12 15:39:07 UTC
Created attachment 139066 [details] [review]
Bug 31314: Remove GetHostItemsInfo and GetItemsInfo from opac-reserve

Bug 27272 is going to remove C4::Items::GetItemsInfo in favour of Koha::Items->search_ordered.

Here we are going to deal with opac-reserve

Test plan:
List items on the modified view and confirm that all the info is
displayed correctly

Signed-off-by: Owen Leonard <oleonard@myacpl.org>

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Comment 6 Nick Clemens 2022-08-12 15:39:10 UTC
Created attachment 139067 [details] [review]
Bug 31314: (QA follow-up) Search Koha::Items not $biblio->items

To get the host items we need to search all items, not those limited to the
same biblionumber

To test:
1 - Enable EasyAnalytics
2 - Attach an item to a record
3 - Confirm it is listed in the items list on opac reserve

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Comment 7 Nick Clemens 2022-08-12 15:39:14 UTC
Created attachment 139068 [details] [review]
Bug 31314: (QA follow-up) Prefetch and make routines use result objects

This reduces lookups for the related items that we now fetch in the templates

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Comment 8 Nick Clemens 2022-08-12 15:41:24 UTC
Passing QA, we probably want Jonathan's nod on the follow-ups or a review by RM before push
Comment 9 Tomás Cohen Arazi 2022-08-16 13:22:14 UTC
Pushed to master for 22.11.

Nice work everyone, thanks!