Go to file
David Cook 1b5cb40fbc Bug 26328: Cast barcode from varchar to integer for incremental barcode
Without this patch, the incremental barcode generation will
treat 978e0143019375 as having an exponent and interpret it as a very
large number.

With this patch, the incremental barcode generation will first cast
barcode varchar strings to integers before finding a max() value.
In this case 978e0143019375 becomes 978 instead of
1.7976931348623157e308

Test plan:

0. Using koha-testing-docker

Before applying patch:

1. Go to http://localhost:8081/cgi-bin/koha/admin/preferences.pl?op=search&searchfield=autobarcode
2. Set to "generated in the form 1, 2, 3"
3. Go to http://localhost:8081/cgi-bin/koha/cataloguing/additem.pl?biblionumber=1#additema&searchid=scs_1607059974968
4. Add item with barcode 978e0143019375
5. Click "p - Barcode"
6. Note the barcode is "Inf"

After applying patch:
1. Go to http://localhost:8081/cgi-bin/koha/cataloguing/additem.pl?biblionumber=1#additema&searchid=scs_1607059974968
2. Click "p - Barcode"
3. Note the barcode is "39999000019194"

Signed-off-by: Marjorie <marjorie.barry-vila@collecto.ca>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit 445cbb373b)

Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com>
2022-04-15 18:13:31 +00:00
C4 Bug 26328: Cast barcode from varchar to integer for incremental barcode 2022-04-15 18:13:31 +00:00
Koha Bug 22993: Handle default messaging preferences during patron creation from API 2022-03-24 17:44:48 +00:00
acqui Bug 29287: Add child funds to display of parent funds on acqui home 2022-03-20 14:58:26 +00:00
admin Bug 29020: Add link on the mainpage for users without admin access 2022-04-15 18:04:06 +00:00
api Bug 28271: Adjust API spec 2022-02-17 20:30:57 +00:00
authorities Bug 28160: Values from 150$a aren't prefilled in z39.50 search form from an existing authority record 2021-05-10 15:52:53 +02:00
basket
…
bin
…
catalogue Bug 29785: Rename Koha::Object->message with ->object_messages 2022-02-21 16:35:20 +00:00
cataloguing Bug 29511: Sort hash keys 2022-02-21 15:22:39 +00:00
circ Bug 26269: "Date due to" and "Show any items currently checked out" filters doesn't work properly in overdues.pl 2022-03-20 15:46:04 +00:00
clubs
…
course_reserves
…
debian Bug 30084: Remove explicit dependency of liblocale-codes-perl 2022-03-20 14:48:51 +00:00
docs Bug 28904: Fix typo and display 2021-11-05 11:59:36 -04:00
errors
…
etc Bug 18540: (QA follow-up) Only mention index_sort_title if defined 2022-02-11 18:50:53 +00:00
ill
…
installer Increment version for 21.05.13 release 2022-03-24 18:44:58 +00:00
koha-tmpl Bug 29020: Add link on the admin module 2022-04-15 18:05:30 +00:00
labels
…
lib/CGI/Session/Serialize Bug 28519: Put CGI::Session::Serialize::yamlxs in lib directory 2021-06-18 11:23:42 -04:00
members Bug 29758: Get rid of warning in members/boraccount.pl 2022-02-11 18:53:57 +00:00
misc Update release notes for 21.05.13 release 2022-03-24 18:59:41 +00:00
offline_circ Bug 29255: Built-in offline circulation broken with SQL error 2021-11-19 10:51:05 -05:00
opac Merge 21.05.12 security branch into 21.05.x 2022-03-15 13:13:25 +00:00
patron_lists
…
patroncards Bug 28576: Update the maximum size of an image. 2022-03-04 14:48:23 +00:00
plugins Bug 29931: [21.05.x] Check cookie status before continuing 2022-03-09 15:09:19 +00:00
pos Bug 28481: (RM follow-up) formatting 2021-12-17 21:22:24 +00:00
reports Bug 28977: Fix cat_issues_top.pl report with strict SQL modes 2022-02-21 16:30:35 +00:00
reserve Bug 29043: Don't fetch items if when are not on the 'Place a hold on' form 2022-02-21 15:28:43 +00:00
reviews
…
rotating_collections
…
serials Bug 23243: Adjust previous patch 2021-04-21 15:25:07 +02:00
services
…
skel
…
suggestion Bug 28946: (bug 23271 follow-up) Missing occurrence in add_user_search.pl 2021-10-01 13:26:38 -04:00
svc Bug 29931: [21.05.x] Check cookie status before continuing 2022-03-09 15:09:19 +00:00
t Bug 30035: Fix failing test 2022-04-15 17:46:52 +00:00
tags
…
tmp/modified_authorities
…
tools Bug 28576: Update the maximum size of an image. 2022-03-04 14:48:23 +00:00
virtualshelves Bug 29542: Prevent access to private list to non authorized users 2022-01-28 14:17:15 +00:00
xt Bug 28370: Rewrite tests 2021-05-25 09:28:18 +02:00
.editorconfig
…
.eslintrc.json
…
.gitignore
…
.htaccess
…
.mailmap Bug 28386: Disambiguate Tomas and Blou 2021-05-26 12:30:59 +02:00
.perlcriticrc
…
.scss-lint.yml
…
INSTALL
…
Koha.pm Increment version for 21.05.13 release 2022-03-24 18:44:58 +00:00
LICENSE
…
MANIFEST.SKIP
…
Makefile.PL Bug 28519: Put CGI::Session::Serialize::yamlxs in lib directory 2021-06-18 11:23:42 -04:00
README
…
README.md
…
README.robots
…
about.pl Bug 28870: Move email address validation to a specific class method 2021-11-15 07:21:49 -05:00
app.psgi
…
changelanguage.pl
…
cpanfile Bug 30084: Remove dependency of liblocale-codes-perl (follow-up) 2022-03-20 14:49:03 +00:00
fix-perl-path.PL
…
gulpfile.js
…
help.pl
…
koha_perl_deps.pl
…
kohaversion.pl
…
mainpage.pl Bug 29020: Add link on the mainpage for users without admin access 2022-04-15 18:04:06 +00:00
package.json
…
rewrite-config.PL Bug 28519: Put CGI::Session::Serialize::yamlxs in lib directory 2021-06-18 11:23:42 -04:00
yarn.lock
…

README.md

Koha is a free software integrated library system (ILS).

Koha is distributed under the GNU GPL version 3 or later.

Note: Koha does not accept pull requests from git hosting sites.

Note: This project has its own bug tracker, to report a bug or submit a patch visit http://bugs.koha-community.org.

For guidelines on submitting patches for Koha please visit https://wiki.koha-community.org/wiki/SubmitingAPatch

The developers handbook can be found at https://wiki.koha-community.org/wiki/Developer_handbook

http://koha-community.org/

Koha Logo