]> 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>
Mon, 12 Aug 2024 18:35:07 +0000 (15:35 -0300)
commit8d1d82443633587d49d6320448eefd11bb8fd45d
treec646dad85886adc415eac0609807cac42658591b
parent29daece9bc0fe6a25774ea2b73023888863df7d6
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