[Bug 24535] New: Add the ability to have longer barcodes than 20 digits
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24535 Bug ID: 24535 Summary: Add the ability to have longer barcodes than 20 digits Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: enhancement Priority: P5 - low Component: Cataloging Assignee: nick@bywatersolutions.com Reporter: kelly@bywatersolutions.com QA Contact: testopia@bugs.koha-community.org CC: m.de.rooy@rijksmuseum.nl Currently, in Koha, an item's barcode can only be up to 20 digits, it would be nice to increase this value to possibly a higher number such as 32. Koha recently increased the patron's barcode length to 32 and it was helpful to libraries. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24535 Jonathan Druart <jonathan.druart@bugs.koha-community.org> changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://bugs.koha-community | |.org/bugzilla3/show_bug.cgi | |?id=25385 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24535 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |kyle@bywatersolutions.com -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24535 Janusz Kaczmarek <januszop@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |januszop@gmail.com --- Comment #1 from Janusz Kaczmarek <januszop@gmail.com> --- I strongly support this idea. Limiting the barcode length to 20 is insufficient for some libraries. Until now, it was possible to locally increase the barcode length in the items.barcode table; however, after introducing length validation in the API via Bug 40176, such local solutions no longer work and require additional local fixes. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24535 Janusz Kaczmarek <januszop@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Severity|enhancement |normal Priority|P5 - low |P3 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24535 Janusz Kaczmarek <januszop@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24535 --- Comment #2 from Janusz Kaczmarek <januszop@gmail.com> --- Created attachment 197279 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=197279&action=edit Bug 24535: DB updates BTW, Koha/Schema/Result/Item.pm need to be updated as well -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24535 --- Comment #3 from Janusz Kaczmarek <januszop@gmail.com> --- Created attachment 197280 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=197280&action=edit Bug 24535: Add the ability to have longer barcodes than 20 digits Currently, in Koha, an item's barcode can only be up to 20 digits, it would be nice to increase this value to possibly a higher number such as 32. Koha recently increased the patron's barcode length to 32 and it was helpful to libraries. OpenAPI adjustments for item's barcode maxLength. Test plan: ---------- 1. In item editing, enter a barcode longer than 20 characters, e.g. 987654321098765432109876543210. 2. The barcode will not be saved (cf. Bug 42355). In a production environment without SQL strict mode, the barcode will be truncated to 20 characters. 3. apply patch; updatedatabase; ; yarn build; restart_all 4. Again, in item editing, enter a barcode longer than 20 characters, e.g. 987654321098765432109876543210. 5. Verify that the barcode is now saved in full. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24535 --- Comment #4 from Janusz Kaczmarek <januszop@gmail.com> --- BTW, a local database change and barcodes longer than 20 characters, after applying Bug 40176, result in the following message in Normal View when loading the items table: Something went wrong when loading the table. 500: Internal Server Error. String is too long: 25/20.Have a look at the 'Audit' button in the toolbar However, the Audit button does not provide any explanation. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24535 Nick Clemens (kidclamp) <nick@bywatersolutions.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=24535 Nick Clemens (kidclamp) <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #197279|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=24535 Nick Clemens (kidclamp) <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #197280|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=24535 --- Comment #5 from Nick Clemens (kidclamp) <nick@bywatersolutions.com> --- Created attachment 197502 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=197502&action=edit Bug 24535: DB updates BTW, Koha/Schema/Result/Item.pm need to be updated as well 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=24535 --- Comment #6 from Nick Clemens (kidclamp) <nick@bywatersolutions.com> --- Created attachment 197503 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=197503&action=edit Bug 24535: Add the ability to have longer barcodes than 20 digits Currently, in Koha, an item's barcode can only be up to 20 digits, it would be nice to increase this value to possibly a higher number such as 32. Koha recently increased the patron's barcode length to 32 and it was helpful to libraries. OpenAPI adjustments for item's barcode maxLength. Test plan: ---------- 1. In item editing, enter a barcode longer than 20 characters, e.g. 987654321098765432109876543210. 2. The barcode will not be saved (cf. Bug 42355). In a production environment without SQL strict mode, the barcode will be truncated to 20 characters. 3. apply patch; updatedatabase; ; yarn build; restart_all 4. Again, in item editing, enter a barcode longer than 20 characters, e.g. 987654321098765432109876543210. 5. Verify that the barcode is now saved in full. 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=24535 Nick Clemens (kidclamp) <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|nick@bywatersolutions.com |januszop@gmail.com -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24535 Nick Clemens (kidclamp) <nick@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |nick@bywatersolutions.com --- Comment #7 from Nick Clemens (kidclamp) <nick@bywatersolutions.com> --- Created attachment 197504 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=197504&action=edit Test KOC file Add an item with barcode 1234567890123456789012345 Upload via circulation -> upload offline circulation file -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24535 Jonathan Druart <jonathan.druart@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |jonathan.druart@gmail.com --- Comment #8 from Jonathan Druart <jonathan.druart@gmail.com> --- Should this be adjusted as well? C4/Labels/Label.pm 539 #NOTE: Barcode length algorithm comes from PDF::Reuse::Barcode 540 #NOTE: 20 is arbitrary padding added to the barcode background by PDF::Reuse::Barcode 541 my $oGdB = GD::Barcode::Code39->new("*$params{'barcode_data'}*"); 542 my $whole_barcode_length = ( length( $oGdB->barcode() ) * 0.9 ) + 20; -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24535 --- Comment #9 from Jonathan Druart <jonathan.druart@gmail.com> --- Created attachment 197774 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=197774&action=edit Bug 24535: Add tests Patch from commit 2f61401 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=24535 Jonathan Druart <jonathan.druart@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |In Discussion --- Comment #10 from Jonathan Druart <jonathan.druart@gmail.com> --- And this one? 28 koha-tmpl/opac-tmpl/bootstrap/en/modules/sco/sco-main.tt: <input id="barcode" name="barcode" size="20" type="text" class="focus form-control" autocomplete="off" / > -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org