[Koha-bugs] [Bug 17499] Koha objects for messaging preferences

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Mon May 29 14:31:58 CEST 2017


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

Marc Véron <veron at veron.ch> changed:

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

--- Comment #23 from Marc Véron <veron at veron.ch> ---
Created attachment 63806
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=63806&action=edit
Bug 17499: Add a method for setting default messaging preferences

This patch adds a method Koha::Patron::Message::Preference->new_from_default
that
can be used to add category's default messaging preferences to patron for a
given
message type.

Example call:

Koha::Patron::Message::Preference->new_from_default({
    borrowernumber => 123,
    categorycode => "ABC",
    message_attribute_id => 1,
});

Also adds a simple method for Koha::Patron, set_default_messaging_preferences.
Usage: $patron->set_default_messaging_preferences()

To test:
1. Run t/db_dependent/Koha/Patron/Message/Preferences.t

Signed-off-by: Marc Véron <veron at veron.ch>

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


More information about the Koha-bugs mailing list