[Bug 18266] New: Internal Server Error when paying fine for lost item
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18266 Bug ID: 18266 Summary: Internal Server Error when paying fine for lost item Change sponsored?: --- Product: Koha Version: unspecified Hardware: All OS: All Status: NEW Severity: normal Priority: P5 - low Component: Circulation Assignee: koha-bugs@lists.koha-community.org Reporter: veron@veron.ch QA Contact: testopia@bugs.koha-community.org CC: gmcharlt@gmail.com, kyle.m.hall@gmail.com To reproduce: - Create a Manual invoice for a patron, select Type: Lost Item - Do not fill in Barcode, Description - Give the invoice an amount that is easy to identify - Go to tab "Pay fines" - Identify row of new fine, click "Pay" - On the following page, click "Confirm" Result: "Internal Server Error" plack error log says: Can't call method "last_returned_by" on an undefined value at /home/marc/koha/C4/Circulation.pm line 2188. - Repeat steps above, insert a valid Barcode of an item that is lost. Same result. -- 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=18266 Marc Véron <veron@veron.ch> changed: What |Removed |Added ---------------------------------------------------------------------------- Version|unspecified |master --- Comment #1 from Marc Véron <veron@veron.ch> --- Following finding: sub pay in Koha/Account.pm line 106 triggers C4::Circulation::ReturnLostItem ( $self->{patron_id}, $fine->itemnumber ); $fine->itemnumber is not defined. But should payment for a lost item mark the item as returned? Payment for an item that is lost does not necessarily mean that the item is already replaced or will be replaced at all. -- 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=18266 --- Comment #2 from Marc Véron <veron@veron.ch> --- (In reply to Marc Véron from comment #1)
Following finding:
But should payment for a lost item mark the item as returned?
Payment for an item that is lost does not necessarily mean that the item is already replaced or will be replaced at all.
Please ignore this comment - of course the item should be marked as returned. I think - it should not be possible to create a manual invoice for a lost item or alternatively the barcode should be verified and the item should be set to LOST (not in the scope of this bug) - paying a fine for a lost item without having a barcode should not result in an internal server error (scope of this bug) -- 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=18266 Olli-Antti Kivilahti <olli-antti.kivilahti@jns.fi> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |18289 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18289 [Bug 18289] Fix t/Prices.t having a Test::DBIx::Class cache issue -- 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=18266 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jonathan.druart@bugs.koha-c | |ommunity.org --- Comment #3 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- To recreate you need StoreLastBorrower -- 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=18266 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |Needs Signoff -- 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=18266 --- Comment #4 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 61402 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=61402&action=edit Bug 18266: Fix internal error when paying fine for lost item without.. item If a fine is created for a lost item but the itemnumber is not supplied, the system will return it. The item should not be mark as returned if there is no item linked to the fine. Test plan: 1. Turn StoreLastBorrower on 2. Create a manual invoice for a lost item, do not supply a barcode 3. Pay the fines 'Pay fines > Pay' => Without this patch applied you get Can't call method "last_returned_by" on an undefined value at /home/marc/koha/C4/Circulation.pm line 2188. => With this patch applied, you must not get the error. -- 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=18266 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 Severity|normal |major -- 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=18266 Marc Véron <veron@veron.ch> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #61402|0 |1 is obsolete| | --- Comment #5 from Marc Véron <veron@veron.ch> --- Created attachment 61439 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=61439&action=edit Bug 18266: Fix internal error when paying fine for lost item without.. item If a fine is created for a lost item but the itemnumber is not supplied, the system will return it. The item should not be mark as returned if there is no item linked to the fine. Test plan: 1. Turn StoreLastBorrower on 2. Create a manual invoice for a lost item, do not supply a barcode 3. Pay the fines 'Pay fines > Pay' => Without this patch applied you get Can't call method "last_returned_by" on an undefined value at /home/marc/koha/C4/Circulation.pm line 2188. => With this patch applied, you must not get the error. Signed-off-by: Marc Véron <veron@veron.ch> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18266 Marc Véron <veron@veron.ch> 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=18266 Marc Véron <veron@veron.ch> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks|18289 | Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18289 [Bug 18289] Fix t/Prices.t having a Test::DBIx::Class cache issue -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18266 Mason James <mtj@kohaaloha.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |mtj@kohaaloha.com -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18266 Nick Clemens <nick@bywatersolutions.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=18266 Nick Clemens <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #61439|0 |1 is obsolete| | --- Comment #6 from Nick Clemens <nick@bywatersolutions.com> --- Created attachment 61687 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=61687&action=edit Bug 18266: Fix internal error when paying fine for lost item without.. item If a fine is created for a lost item but the itemnumber is not supplied, the system will return it. The item should not be mark as returned if there is no item linked to the fine. Test plan: 1. Turn StoreLastBorrower on 2. Create a manual invoice for a lost item, do not supply a barcode 3. Pay the fines 'Pay fines > Pay' => Without this patch applied you get Can't call method "last_returned_by" on an undefined value at /home/marc/koha/C4/Circulation.pm line 2188. => With this patch applied, you must not get the error. Signed-off-by: Marc Véron <veron@veron.ch> Signed-off-by: Nick Clemens <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=18266 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |Pushed to Master CC| |kyle@bywatersolutions.com --- Comment #7 from Kyle M Hall <kyle@bywatersolutions.com> --- Pushed to master for 17.05, thanks Jonathan! -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18266 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |katrin.fischer@bsz-bw.de --- Comment #8 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- I was able to reproduce this error on 16.11.x, but the patch doesn't apply cleanly. There is a conflict in Koha/Account.pm. Jonathan, could you please take a look? I'd really like this for 16.11.07. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18266 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #61687|0 |1 is obsolete| | --- Comment #9 from Jonathan Druart <jonathan.druart@bugs.koha-community.org> --- Created attachment 61795 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=61795&action=edit [16.11.x] Bug 18266: Fix internal error when paying fine for lost item without.. item If a fine is created for a lost item but the itemnumber is not supplied, the system will return it. The item should not be mark as returned if there is no item linked to the fine. Test plan: 1. Turn StoreLastBorrower on 2. Create a manual invoice for a lost item, do not supply a barcode 3. Pay the fines 'Pay fines > Pay' => Without this patch applied you get Can't call method "last_returned_by" on an undefined value at /home/marc/koha/C4/Circulation.pm line 2188. => With this patch applied, you must not get the error. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18266 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to Master |Pushed to Stable --- Comment #10 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- This patch has been pushed to 16.11.x and will be in 16.11.07. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18266 Julian Maurice <julian.maurice@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |julian.maurice@biblibre.com --- Comment #11 from Julian Maurice <julian.maurice@biblibre.com> --- Pushed to 3.22.x for 3.22.20 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18266 --- Comment #12 from Mason James <mtj@kohaaloha.com> --- Pushed to 16.05.x, for 16.05.12 release -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18266 Mirko Tietgen <mirko@abunchofthings.net> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |18851 See Also| |https://bugs.koha-community | |.org/bugzilla3/show_bug.cgi | |?id=18851 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18851 [Bug 18851] use Test::DBIx::Class in 00-load.t breaks packaging -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18266 Mirko Tietgen <mirko@abunchofthings.net> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks|18851 | See Also|https://bugs.koha-community | |.org/bugzilla3/show_bug.cgi | |?id=18851 | Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=18851 [Bug 18851] use Test::DBIx::Class in 00-load.t breaks packaging -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org