]> git.koha-community.org Git - koha.git/commit
Bug 23064: Use Koha::Subscription in ModSubscription
authorJonathan Druart <jonathan.druart@bugs.koha-community.org>
Wed, 20 Nov 2019 11:22:58 +0000 (12:22 +0100)
committerHayley Mapley <hayleymapley@catalyst.net.nz>
Sun, 23 Feb 2020 21:37:10 +0000 (10:37 +1300)
commit89ab97da996acbe7ead156f03a8f72b520301669
treebf3b5e09593c3c521e9e7c06e4ef8e381a415d77
parent610a6cf78bdced8b43a4dcb275b9b858f536ac11
Bug 23064: Use Koha::Subscription in ModSubscription

We must use Koha::Subscription instead of raw SQL.
It will fix issue with default and integer values.

Test plan:
Edit a subscription and set number of issues = "f"
Save
=> Without this patch there is a SQL error in the log:
  Incorrect integer value: 'f' for column 'numberlength'
=> With this patch the other changes are effective.

Note: We also could change the type attribute of the input to "number",
to have a client-side check

Also, the return value of ModSuggestion is never used, so we are safe
with that.

Signed-off-by: Hayley Mapley <hayleymapley@catalyst.net.nz>
The <strict_sql_modes> flag must be present and set to 1 in the <config> section of koha-conf.xml

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Hayley Mapley <hayleymapley@catalyst.net.nz>
C4/Serials.pm