[Bug 25670] New: Add a method to search by ordernumber on transfered ones as well to K:A:Orders
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 Bug ID: 25670 Summary: Add a method to search by ordernumber on transfered ones as well to K:A:Orders Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: enhancement Priority: P5 - low Component: Acquisitions Assignee: koha-bugs@lists.koha-community.org Reporter: tomascohen@gmail.com QA Contact: testopia@bugs.koha-community.org This is something that happens in C4::Acquisition::SearchOrders and is needed to be used on the API controller. -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|koha-bugs@lists.koha-commun |tomascohen@gmail.com |ity.org | -- 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=25670 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |20212 Status|NEW |ASSIGNED Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=20212 [Bug 20212] Slowness in Receiving in Acquisitions -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 --- Comment #1 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Created attachment 105534 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=105534&action=edit Bug 25670: Unit tests -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 --- Comment #2 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Created attachment 105535 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=105535&action=edit Bug 25670: Add Koha::Acquisition::Orders->filter_by_id_including_transfers This patch introduces a method to filter on the ordernumber, looking for it on the aqorders_transfers table ('ordernumber_from' field). To test: 1. Apply this patches 2. Run: $ kshell k$ prove t/db_dependent/Koha/Acquisition/Orders.t => SUCCESS: Tests pass! 3. Sign off :-D -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 Tomás Cohen Arazi <tomascohen@gmail.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=25670 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |tomascohen@gmail.com -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #105534|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=25670 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #105535|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=25670 --- Comment #3 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Created attachment 109859 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=109859&action=edit Bug 25670: Unit tests -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 --- Comment #4 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Created attachment 109860 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=109860&action=edit Bug 25670: Add filter_by_active and filter_by_id_including_transfers This patch introduces a method to filter on the ordernumber, looking for it on the aqorders_transfers table ('ordernumber_from' field). It also adds a method for filtering on active orders. To test: 1. Apply this patches 2. Run: $ kshell k$ prove t/db_dependent/Koha/Acquisition/Orders.t => SUCCESS: Tests pass! 3. Sign off :-D lib -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|Add a method to search by |Add useful methods to |ordernumber on transfered |Koha::Acquisition::Orders |ones as well to K:A:Orders | CC| |jonathan.druart@bugs.koha-c | |ommunity.org, | |kyle@bywatersolutions.com, | |martin.renvoize@ptfs-europe | |.com, | |nick@bywatersolutions.com -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #109859|0 |1 is obsolete| | --- Comment #5 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Created attachment 110643 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=110643&action=edit Bug 25670: Unit tests Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #109860|0 |1 is obsolete| | --- Comment #6 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Created attachment 110644 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=110644&action=edit Bug 25670: Add filter_by_active and filter_by_id_including_transfers This patch introduces a method to filter on the ordernumber, looking for it on the aqorders_transfers table ('ordernumber_from' field). It also adds a method for filtering on active orders. To test: 1. Apply this patches 2. Run: $ kshell k$ prove t/db_dependent/Koha/Acquisition/Orders.t => SUCCESS: Tests pass! 3. Sign off :-D lib Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off --- Comment #7 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Code reads well, tests are good.. Signing off -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 --- Comment #8 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- -=head2 Class Methods +=head2 Class methods Thank you! I wonder if $orders->filter_by_active is a good name. Maybe filter_by_pending ? -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA Patch complexity|--- |Small patch -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #110643|0 |1 is obsolete| | --- Comment #9 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Created attachment 110700 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=110700&action=edit Bug 25670: Unit tests Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #110644|0 |1 is obsolete| | --- Comment #10 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Created attachment 110701 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=110701&action=edit Bug 25670: Add filter_by_active and filter_by_id_including_transfers This patch introduces a method to filter on the ordernumber, looking for it on the aqorders_transfers table ('ordernumber_from' field). It also adds a method for filtering on active orders. To test: 1. Apply this patches 2. Run: $ kshell k$ prove t/db_dependent/Koha/Acquisition/Orders.t => SUCCESS: Tests pass! 3. Sign off :-D lib Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- QA Contact|testopia@bugs.koha-communit |katrin.fischer@bsz-bw.de |y.org | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 --- Comment #11 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Created attachment 114940 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=114940&action=edit Bug 25670: Regression tests 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=25670 --- Comment #12 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Created attachment 114941 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=114941&action=edit Bug 25670: New orders included only if standing The original implementation included new orders regardless they were standing orders. This patch makes the query respect that conditions found on C4::Acquisitions::SearchOrders. To test: 1. Apply the regression tests patch 2. Run: $ kshell k$ prove t/db_dependent/Koha/Acquisition/Orders.t => FAIL: More orders than expected are returned 3. Apply this patch 4. Repeat 2 => SUCCESS: Tests pass! New orders are only considered if the basket they are attached to, is marked as standing! 5. Verify the tests make sense 6. Sign off :-D 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=25670 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Version(s)| |21.05.00 released in| | Status|Passed QA |Pushed to master -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 --- Comment #13 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Pushed to master for 21.05, 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=25670 --- Comment #14 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 116141 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=116141&action=edit Bug 25670: Fix random failure on Orders.t It has failed at least 3 times: # Failed test 'The right order is returned' # at t/db_dependent/Koha/Acquisition/Orders.t line 153. # got: '50' # expected: '49' # Failed test 'The right order is returned' # at t/db_dependent/Koha/Acquisition/Orders.t line 154. # got: '49' # expected: '50' # Looks like you failed 2 tests of 6. I cannot manage to make it fail locally -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 --- Comment #15 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Follow-up pushed to master. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 Fridolin Somers <fridolin.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |fridolin.somers@biblibre.co | |m --- Comment #16 from Fridolin Somers <fridolin.somers@biblibre.com> --- Enhancement not pushed to 20.11.x -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |caroline.cyr-la-rose@inlibr | |o.com -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 --- Comment #17 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- (In reply to Jonathan Druart from comment #14)
Created attachment 116141 [details] [review] Bug 25670: Fix random failure on Orders.t
It has failed at least 3 times:
# Failed test 'The right order is returned' # at t/db_dependent/Koha/Acquisition/Orders.t line 153. # got: '50' # expected: '49'
# Failed test 'The right order is returned' # at t/db_dependent/Koha/Acquisition/Orders.t line 154. # got: '49' # expected: '50' # Looks like you failed 2 tests of 6.
I cannot manage to make it fail locally
Again today Koha_Master_D9 #1564: 16:34:46 koha_1 | # Failed test 'The 2 orders are returned' 16:34:46 koha_1 | # at t/db_dependent/Koha/Acquisition/Orders.t line 152. 16:34:46 koha_1 | # Structures begin differing at: 16:34:46 koha_1 | # $got->[0] = '100' 16:34:46 koha_1 | # $expected->[0] = '99' 16:34:46 koha_1 | # Looks like you failed 1 test of 4. 16:34:46 koha_1 | 16:34:46 koha_1 | # Failed test 'filter_by_id_including_transfers() tests' 16:34:46 koha_1 | # at t/db_dependent/Koha/Acquisition/Orders.t line 160. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 --- Comment #18 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Master_D10 (#484) 14:03:26 koha_1 | # Failed test 'The 2 orders are returned' 14:03:26 koha_1 | # at t/db_dependent/Koha/Acquisition/Orders.t line 152. 14:03:26 koha_1 | # Structures begin differing at: 14:03:26 koha_1 | # $got->[0] = '10' 14:03:26 koha_1 | # $expected->[0] = '9' 14:03:26 koha_1 | # Looks like you failed 1 test of 4. 14:03:26 koha_1 | 14:03:26 koha_1 | # Failed test 'filter_by_id_including_transfers() tests' 14:03:26 koha_1 | # at t/db_dependent/Koha/Acquisition/Orders.t line 160. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |additional_work_needed -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Text to go in the| |This architectural release notes| |enhancement adds helpful | |filter methods to the | |Koha::Acquisitions:: | |modules to ease the | |development of Acquisitions | |API's and future | |acquisitions related | |enhancements. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Component|Acquisitions |Architecture, internals, | |and plumbing -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 Fridolin Somers <fridolin.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |28509 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28509 [Bug 28509] Koha/Acquisition/Orders.t is failing randomly -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Resolution|--- |FIXED Status|Pushed to master |RESOLVED -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 --- Comment #19 from Fridolin Somers <fridolin.somers@biblibre.com> --- Still additional_work_needed ? Looks like there has been : Bug 20212: Fix test after 25670 follow-up -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 --- Comment #20 from Jonathan Druart <jonathan.druart+koha@gmail.com> --- (In reply to Fridolin Somers from comment #19)
Still additional_work_needed ?
Looks like there has been : Bug 20212: Fix test after 25670 follow-up
CommitDate: Thu Jan 28 16:44:12 2021 +0100 Last comment is from March. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |30092 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=30092 [Bug 30092] Random failure in t/db_dependent/Koha/Acquisition/Orders.t -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 --- Comment #21 from Jonathan Druart <jonathan.druart+koha@gmail.com> --- Tomas opened bug 30092 to track this random failure. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25670 Fridolin Somers <fridolin.somers@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords|additional_work_needed | -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org