[Koha-bugs] [Bug 30076] Add ability to check patron messaging preferences from a notice

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Tue Mar 29 00:21:54 CEST 2022


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

Katrin Fischer <katrin.fischer at bsz-bw.de> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
 Attachment #132324|0                           |1
        is obsolete|                            |

--- Comment #7 from Katrin Fischer <katrin.fischer at bsz-bw.de> ---
Created attachment 132374
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=132374&action=edit
Bug 30076: Add ability to check patron messaging preferences from a notice

Some libraries want to be able to use a patron's messaging preferences to
conditionally change the contents of a notice depending on the patron's other
messaging preference. For example, a library has requested to have the note on
the hold slip if the patron has requested phone messages for waiting holds.
This really only entails adding a method to the Koha::Patron class to allow
this type of looking.

Test plan:
1) Apply this patch
2) Enable item checkout notices for a patron for email, but not sms
3) Include the following in the notice:
   TEST1: [% borrower.has_messaging_preference({ message_name =>
'Item_Checkout', message_transport_type => 'email' }) %]
   <br/>
   TEST2: [% borrower.has_messaging_preference({ message_name =>
'Item_Checkout', message_transport_type => 'sms' }) %]
4) Generate a checkout and notice for that patron
5) Note the generated notice has a 1 for TEST1, but not for TEST2

Signed-off-by: Lucas Gass <lucas at bywatersolutions.com>

Signed-off-by: Katrin Fischer <katrin.fischer.83 at web.de>

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


More information about the Koha-bugs mailing list