[Bug 27002] New: Make Koha::Biblio->pickup_locations return a Koha::Libraries resultset
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27002 Bug ID: 27002 Summary: Make Koha::Biblio->pickup_locations return a Koha::Libraries resultset Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: enhancement Priority: P5 - low Component: Architecture, internals, and plumbing Assignee: koha-bugs@lists.koha-community.org Reporter: tomascohen@gmail.com QA Contact: testopia@bugs.koha-community.org For consistency and better handling, it should follow the bug 26963 implementation. -- 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=27002 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Depends on| |26963 Assignee|koha-bugs@lists.koha-commun |martin.renvoize@ptfs-europe |ity.org |.com Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26963 [Bug 26963] Improve Koha::Item::pickup_locations performance -- 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=27002 --- Comment #1 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Created attachment 113548 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=113548&action=edit Bug 27002: Update Koha::Biblio->pickup_locations to return a resultset -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27002 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |rel_20_11_target CC| |jonathan.druart@bugs.koha-c | |ommunity.org --- Comment #2 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Can we have this for 20.11 please? -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27002 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED QA Contact|testopia@bugs.koha-communit |tomascohen@gmail.com |y.org | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27002 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #113548|0 |1 is obsolete| | --- Comment #3 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Created attachment 113610 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=113610&action=edit Bug 27002: Update Koha::Biblio->pickup_locations to return a resultset -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27002 --- Comment #4 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Created attachment 113611 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=113611&action=edit Bug 27002: Update callers for changed return -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27002 --- Comment #5 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Created attachment 113612 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=113612&action=edit Bug 27002: (follow-up) Fix empty Koha::Item->pickup_locations In Koha::Item pickup_locations we were using the Koha::Objects->empty to return an effectively empty Koha::Libraries object. However, this only sets the result cache to an empty arrayref and as such only affect iterators and not subsequent chained queries (like the get_column I call to get back a DBIx::Class:ResultSetColumn in this patchset). As such, this patch updates the Koha::Item->pickup_locations method to use an always empty search ->search(\'0 = 1') to fulfil the same purpose as the prior call to empty and return an empty set that is available for both iterating and query chaining. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27002 Martin Renvoize <martin.renvoize@ptfs-europe.com> 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=27002 --- Comment #6 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Gotta love unit tests.. that last one was hard to pin down. Our ->empty method in Koha::Objects is interesting.. as the commit comment says it Only resets the query result cache (which affects the iterating methods) but does NOT set anything for the query itself.. as such it's like having a brand new object when chaining as as such will return the opposite of what you want.. ALL rows rather than NONE when used in a query chain. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27002 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Depends on| |27021 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27021 [Bug 27021] Chaining on Koha::Objects->empty should always return an empty resultset -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27002 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |tomascohen@gmail.com 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=27002 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #113610|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=27002 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #113611|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=27002 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #113612|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=27002 --- Comment #7 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Created attachment 113628 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=113628&action=edit Bug 27002: Update Koha::Biblio->pickup_locations to return a resultset -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27002 --- Comment #8 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Created attachment 113629 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=113629&action=edit Bug 27002: Update callers for changed return -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27002 --- Comment #9 from Tomás Cohen Arazi <tomascohen@gmail.com> --- I removed the last patch, as I made this dependent on bug 27021, which is the proper solution to the issue. No QA complaints, ran: $ prove t/db_dependent/Koha/Biblio.t \ t/db_dependent/Template/Plugin/Branches.t \ t/db_dependent/Koha/Item.t \ t/db_dependent/api/v1/holds.t -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27002 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |27015 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27015 [Bug 27015] Add filtering options to the pickup_locations routes -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27002 --- Comment #10 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Great work, thanks Tomas. Nice to have this fix further up the stack.. I wasn't confident enough in its current callers to do that myself, but trust your judgement there. 😀 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27002 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Needs Signoff --- Comment #11 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Setting NSO so we get a tester. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27002 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |andrew@bywatersolutions.com | |, david@davidnind.com, | |nick@bywatersolutions.com, | |victor@tuxayo.net -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27002 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=27002 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #113628|0 |1 is obsolete| | --- Comment #12 from David Nind <david@davidnind.com> --- Created attachment 113642 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=113642&action=edit Bug 27002: Update Koha::Biblio->pickup_locations to return a resultset 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=27002 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #113629|0 |1 is obsolete| | --- Comment #13 from David Nind <david@davidnind.com> --- Created attachment 113643 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=113643&action=edit Bug 27002: Update callers for changed return 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=27002 --- Comment #14 from David Nind <david@davidnind.com> --- Signed off based on running the tests in Comment #9 before and after without any fails is sufficient as a test plan. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27002 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27002 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #113642|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=27002 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #113643|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=27002 --- Comment #15 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Created attachment 113658 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=113658&action=edit Bug 27002: Update Koha::Biblio->pickup_locations to return a resultset Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27002 --- Comment #16 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Created attachment 113659 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=113659&action=edit Bug 27002: Update callers for changed return Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27002 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |Pushed to master Version(s)| |20.11.00 released in| | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27002 --- Comment #17 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Pushed to master for 20.11, thanks to everybody involved! -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27002 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords|rel_20_11_target | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27002 Bug 27002 depends on bug 26963, which changed state. Bug 26963 Summary: Improve Koha::Item::pickup_locations performance https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=26963 What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to stable |RESOLVED Resolution|--- |FIXED -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27002 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |27062 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27062 [Bug 27062] pickup_location tests don't deal correctly with existing libraries -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27002 --- Comment #18 from Andrew Fuerste-Henry <andrew@bywatersolutions.com> --- Enhancement, not backporting to 20.05 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27002 Bug 27002 depends on bug 27021, which changed state. Bug 27021 Summary: Chaining on Koha::Objects->empty should always return an empty resultset https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27021 What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to oldstable |RESOLVED Resolution|--- |FIXED -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27002 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to master |RESOLVED Resolution|--- |FIXED -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27002 Andrew Fuerste-Henry <andrew@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Version(s)|20.11.00 |20.11.00, 20.05.07 released in| | --- Comment #19 from Andrew Fuerste-Henry <andrew@bywatersolutions.com> --- Pushed to 20.05.x for 20.05.07. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=27002 --- Comment #20 from Victor Grousset/tuxayo <victor@tuxayo.net> --- Not backported to oldoldstable (19.11.x). Feel free to ask if it's needed. -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org