[Bug 40471] New: Long barcodes in "Add item" throw 500 error
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=40471 Bug ID: 40471 Summary: Long barcodes in "Add item" throw 500 error Change sponsored?: --- Product: Koha Version: Main Hardware: All OS: All Status: NEW Severity: minor Priority: P5 - low Component: Cataloging Assignee: koha-bugs@lists.koha-community.org Reporter: dcook@prosentient.com.au QA Contact: testopia@bugs.koha-community.org CC: m.de.rooy@rijksmuseum.nl If you try to enter a very long barcode for an item in the "Add item" screen, you'll get a 500 error and the following in the logs: [WARN] DBIx::Class::Storage::DBI::_dbh_execute(): DBI Exception: DBD::mysql::st execute failed: Data too long for column 'barcode' at row 1 at /kohadevbox/koha/Koha/Object.pm line 174 It should be trivial for us to add length limit checks in the HTML and the Perl. -- 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=40471 David Cook <dcook@prosentient.com.au> changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://bugs.koha-community | |.org/bugzilla3/show_bug.cgi | |?id=40508 -- 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=40471 --- Comment #1 from David Cook <dcook@prosentient.com.au> --- Owen commented on Mattermost about how the default framework should enforce a maxlength for 952$p, which led me to raise bug 40508 where I've added a patch that does that. We could add a DB update here to set maxlength to 20 if kohafield = 'items.barcode". -- Note: While maxlength does prevent new barcodes from being input that are greater than 20 characters, it doesn't prevent you from saving an item that already has a barcode that is longer than that. -- 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=40471 Andrew Fuerste-Henry <andrew@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |andrew@bywatersolutions.com -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org