Bug 19025

Summary: Move C4::Reserves::GetReserveInfo to Koha::Holds
Product: Koha Reporter: Jonathan Druart <jonathan.druart>
Component: Architecture, internals, and plumbingAssignee: Jonathan Druart <jonathan.druart>
Status: CLOSED FIXED QA Contact: Marcel de Rooy <m.de.rooy>
Severity: enhancement    
Priority: P5 - low CC: fridolin.somers, m.de.rooy
Version: Main   
Hardware: All   
OS: All   
Change sponsored?: --- Patch complexity: Trivial patch
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
Bug Depends on:    
Bug Blocks: 17728, 19055    
Attachments: Bug 19025: Move GetReserveInfo to Koha::Holds
Bug 19025: Remove C4::Reserves::GetReserveInfo
Bug 19025: Move GetReserveInfo to Koha::Holds
Bug 19025: Remove C4::Reserves::GetReserveInfo

Description Jonathan Druart 2017-08-02 14:43:55 UTC
This subroutine is only used once and can be replaced with a call to Koha::Holds->find
It will avoid unnecessary joins.
Comment 1 Jonathan Druart 2017-08-02 14:53:05 UTC
Created attachment 65428 [details] [review]
Bug 19025: Move GetReserveInfo to Koha::Holds

This subroutine is only used once and can be replaced with a call to
Koha::Holds->find
It will avoid unnecessary joins.

Test plan:
- Define a HOLD_SLIP template notice using fields from the tables
reserves, branches, borrowers, biblio, biblioitems and items.
- Generate one and make sure the values are correctly filled
Comment 2 Jonathan Druart 2017-08-02 14:53:08 UTC
Created attachment 65429 [details] [review]
Bug 19025: Remove C4::Reserves::GetReserveInfo

Test plan:
  git grep GetReserveInfo
should not return results
Comment 3 Marcel de Rooy 2017-08-03 06:38:07 UTC
Created attachment 65449 [details] [review]
Bug 19025: Move GetReserveInfo to Koha::Holds

This subroutine is only used once and can be replaced with a call to
Koha::Holds->find
It will avoid unnecessary joins.

Test plan:
- Define a HOLD_SLIP template notice using fields from the tables
reserves, branches, borrowers, biblio, biblioitems and items.
- Generate one and make sure the values are correctly filled

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Comment 4 Marcel de Rooy 2017-08-03 06:38:10 UTC
Created attachment 65450 [details] [review]
Bug 19025: Remove C4::Reserves::GetReserveInfo

Test plan:
  git grep GetReserveInfo
should not return results

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Comment 5 Marcel de Rooy 2017-08-03 06:39:39 UTC
Taking the liberty to pass QA on this relatively simple change.
Comment 6 Jonathan Druart 2017-08-30 20:02:15 UTC
Pushed to master for 17.11, thanks to everybody involved!
Comment 7 Fridolin Somers 2017-09-29 13:35:32 UTC
Enhancement not pushed to 17.05.x