2015-03-03 14:55:30 +05:30
|
|
|
// Copyright (c) 2015, Frappe Technologies Pvt. Ltd. and Contributors
|
2013-08-05 14:59:54 +05:30
|
|
|
// License: GNU General Public License v3. See license.txt
|
|
|
|
|
2013-12-31 17:38:21 +05:30
|
|
|
if(!window.erpnext) window.erpnext = {};
|
2012-12-14 16:39:27 +05:30
|
|
|
|
2015-05-25 10:50:48 +05:30
|
|
|
erpnext.subscribe_to_newsletter = function(opts, btn) {
|
|
|
|
return frappe.call({
|
|
|
|
type: "POST",
|
2016-06-28 11:17:02 +05:30
|
|
|
method: "frappe.email.doctype.newsletter.newsletter.subscribe",
|
2015-05-25 10:50:48 +05:30
|
|
|
btn: btn,
|
|
|
|
args: {"email": opts.email},
|
|
|
|
callback: opts.callback
|
|
|
|
});
|
|
|
|
}
|