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

--- Comment #40 from Josef Moravec <[email protected]> ---
Created attachment 64040
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=64040&action=edit
[SIGNED-OFF] 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 <[email protected]>

Signed-off-by: Josef Moravec <[email protected]>

-- 
You are receiving this mail because:
You are watching all bug changes.
_______________________________________________
Koha-bugs mailing list
[email protected]
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

Reply via email to