]> 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 14:05:27 +0000 (11:05 -0300)
commite0211501384a72481ade9d6ca74162b7d7059dd7
tree11b9d880eb2582fe35f8adaa6045c9b74744d465
parent454314cb0ee70fb5f4b887219e26f488cc70d250
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