]> git.koha-community.org Git - koha.git/commit
Bug 37255: Fix handling of "All" values on waiting hold cancellation policy
authorEmmi Takkinen <emmi.takkinen@koha-suomi.fi>
Thu, 4 Jul 2024 11:23:31 +0000 (14:23 +0300)
committerTomas Cohen Arazi <tomascohen@theke.io>
Tue, 13 Aug 2024 05:03:17 +0000 (02:03 -0300)
commitf340b66acca5a188b0ef3177c745af5b70b24aaa
treefbf09085302af685482b541460e4080de896cda9
parent38ffa70d557771d9b8e90b7d185f9308ac2548a8
Bug 37255: Fix handling of "All" values on waiting hold cancellation policy

If one creates a default waiting hold cancellation policy with
patron categories set as "All" and itemtype set as "All", Koha
breaks on 500 error. This happens because in we try to match
template policy with "All" values either in category or itemtype
with *, not undef. This patch fixes this.

To test:
1. Create a new default waiting hold cancellation policy and
set both patron category and itemtype as "All".
2. Save policy.
=> Error page for error 500 is displayed.
3. Apply this patch.
4. Reload page.
=> Page is displayed and policy listing displays new policy
as it should.

Sponsored-by: Koha-Suomi Oy
Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
koha-tmpl/intranet-tmpl/prog/en/modules/admin/smart-rules.tt