[Koha-bugs] [Bug 31297] Cannot add new subscription patterns from edit subscription page

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Tue Aug 9 12:35:22 CEST 2022


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31297

--- Comment #3 from Jonathan Druart <jonathan.druart+koha at gmail.com> ---
Created attachment 138892
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=138892&action=edit
Bug 31297: Fix creation of new subscription pattern from edit subscription

When editing a subscription there is the possibility to create a new
subscription pattern. But this form does not have a "description" for
this pattern, and the DBMS does not allow description to be NULLed.

Error is: DBI Exception: DBD::mysql::st execute failed: Field 'description'
doesn't have a default value

This patch takes the shortest path to fix the 500 error (with no
feedback sent to the end user), but there are other better ways to fix
it:
1. Allow subscription_numberpatterns.description to be NULL, or
2. Add a description field on the form

Test plan:
Create a new subscription, on the second page click "show advanced
pattern", then "Modify pattern", enter a name and click "Save as new pattern"

-- 
You are receiving this mail because:
You are watching all bug changes.
You are the assignee for the bug.


More information about the Koha-bugs mailing list