[Bug 22390] New: When duplicating existing order lines new items are not created
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22390 Bug ID: 22390 Summary: When duplicating existing order lines new items are not created Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: major Priority: P5 - low Component: Acquisitions Assignee: koha-bugs@lists.koha-community.org Reporter: nick@bywatersolutions.com QA Contact: testopia@bugs.koha-community.org Target Milestone: --- To recreate: 1 - Create a basket set to create items on ordering 2 - Add to this basket, confirm items are created 3 - Add to this basket from the prevous order 4 - Note no new items are created -- 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=22390 Nick Clemens <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Depends on| |15184 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15184 [Bug 15184] Ability to duplicate existing order lines to a given basket -- 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=22390 Andrew <andrew@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |andrew@bywatersolutions.com --- Comment #1 from Andrew <andrew@bywatersolutions.com> --- In our testing, a new item was created if biblio.serial was null but not if biblio.serial was 0. -- 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=22390 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|koha-bugs@lists.koha-commun |jonathan.druart@bugs.koha-c |ity.org |ommunity.org Status|NEW |ASSIGNED CC| |jonathan.druart@bugs.koha-c | |ommunity.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=22390 --- Comment #2 from Andrew <andrew@bywatersolutions.com> --- (In reply to Andrew from comment #1)
In our testing, a new item was created if biblio.serial was null but not if biblio.serial was 0.
Oops, sorry, disregard this. Mis-remembered our testing. No items were created for any value of biblio.serial. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22390 Jonathan Druart <jonathan.druart@bugs.koha-community.org> 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=22390 --- Comment #3 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 85473 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=85473&action=edit Bug 22390: (bug 15184 follow-up) Use aqorders.subscriptionid instead of biblio.serial It seems that we made a wrong assumption on bug 15184, see commit d658cb6f7ecb18845a78d4708ee63ad1126f220f Bug 15184: Do copy items for not a serial OR if items are created on ordering To know if an order has been created from a subscription we should check $order->subscriptionid instead of the $biblio->serial flag -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22390 --- Comment #4 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- (In reply to Andrew from comment #2)
(In reply to Andrew from comment #1)
In our testing, a new item was created if biblio.serial was null but not if biblio.serial was 0.
Oops, sorry, disregard this. Mis-remembered our testing. No items were created for any value of biblio.serial.
Should have been copied for biblio.serial set to 1, but it seems that this behavior was wrong, please test the patch. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22390 Nick Clemens <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Failed QA --- Comment #5 from Nick Clemens <nick@bywatersolutions.com> --- This seems to have improved things - If I copy an order from a basket where effective create items is 'ordering' then a new item is created. However If I copy from a basket that did create items to a new basket that where effective create items is 'cataloging' an item is created, though it should not be. I think the correct condition might be if ( (!$self->subscriptionid) && ($self->basket->effective_create_items eq 'ordering') ) { # Do copy items if not a serial AND if items are created on ordering in this basket -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22390 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22390 --- Comment #6 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 86027 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=86027&action=edit Bug 22390: Never copy items if original order has been created from a subscription -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22390 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #85473|0 |1 is obsolete| | --- Comment #7 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Created attachment 86523 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=86523&action=edit Bug 22390: (bug 15184 follow-up) Use aqorders.subscriptionid instead of biblio.serial It seems that we made a wrong assumption on bug 15184, see commit d658cb6f7ecb18845a78d4708ee63ad1126f220f Bug 15184: Do copy items for not a serial OR if items are created on ordering To know if an order has been created from a subscription we should check $order->subscriptionid instead of the $biblio->serial flag 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=22390 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #86027|0 |1 is obsolete| | --- Comment #8 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Created attachment 86524 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=86524&action=edit Bug 22390: Never copy items if original order has been created from a subscription 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=22390 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |martin.renvoize@ptfs-europe | |.com Status|Needs Signoff |Signed Off --- Comment #9 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Nice catch and followup. Signing Off. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22390 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- 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=22390 Katrin Fischer <katrin.fischer@bsz-bw.de> 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=22390 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #86523|0 |1 is obsolete| | --- Comment #10 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Created attachment 87560 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=87560&action=edit Bug 22390: (bug 15184 follow-up) Use aqorders.subscriptionid instead of biblio.serial It seems that we made a wrong assumption on bug 15184, see commit d658cb6f7ecb18845a78d4708ee63ad1126f220f Bug 15184: Do copy items for not a serial OR if items are created on ordering To know if an order has been created from a subscription we should check $order->subscriptionid instead of the $biblio->serial flag 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=22390 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #86524|0 |1 is obsolete| | --- Comment #11 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Created attachment 87561 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=87561&action=edit Bug 22390: Never copy items if original order has been created from a subscription Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> Tiny change to the code comment: serial => subscription order -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22390 Nick Clemens <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |Pushed to Master --- Comment #12 from Nick Clemens <nick@bywatersolutions.com> --- Awesome work all! Pushed to master for 19.05 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22390 Martin Renvoize <martin.renvoize@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Version(s)| |19.05.00, 18.11.05 released in| | Status|Pushed to Master |Pushed to Stable --- Comment #13 from Martin Renvoize <martin.renvoize@ptfs-europe.com> --- Pushed to 18.11.x for 18.11.05 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22390 Lucas Gass <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |lucas@bywatersolutions.com --- Comment #14 from Lucas Gass <lucas@bywatersolutions.com> --- missing dependency, not backporting to 18.05.x -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22390 Sandre Cunha <cunha@monterey.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |cunha@monterey.org --- Comment #15 from Sandre Cunha <cunha@monterey.org> --- This would be a great enhancement if only it would allow you to change the quantity. Typically we only order 1 copy initially, but if the item is popular, when we re-order we would want to add 2 or 3 (or more) copies. I don't see much advantage of having to replicate this process multiple times, versus just creating a new order with the number of items needed. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22390 --- Comment #16 from Andrew <andrew@bywatersolutions.com> --- Sandre, the use case laid out in the original bug 15184 was focused on cases where you would be copying the whole order exactly -- like serials or databases, where generally you're only going to have a quantity of 1 anyway and it will stay consistent order-to-order. I agree that this is not going to be the easiest way to do what you're doing. For that I'd probably just add to basket from the existing bib. -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org