From 88de00fb9496e8f67f2970bc35104bbb5e952584 Mon Sep 17 00:00:00 2001 From: "FinByz Tech Pvt. Ltd" Date: Thu, 17 Oct 2019 17:12:23 +0530 Subject: [PATCH] Rendered Email template in email Campaign --- erpnext/crm/doctype/email_campaign/email_campaign.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/erpnext/crm/doctype/email_campaign/email_campaign.py b/erpnext/crm/doctype/email_campaign/email_campaign.py index 98e4927beb..6ea24a5f20 100644 --- a/erpnext/crm/doctype/email_campaign/email_campaign.py +++ b/erpnext/crm/doctype/email_campaign/email_campaign.py @@ -73,13 +73,13 @@ def send_mail(entry, email_campaign): email_template = frappe.get_doc("Email Template", entry.get("email_template")) sender = frappe.db.get_value("User", email_campaign.get("sender"), 'email') - + context = { "doc":frappe.get_doc(email_campaign.email_campaign_for,email_campaign.recipient) } # send mail and link communication to document comm = make( doctype = "Email Campaign", name = email_campaign.name, subject = email_template.get("subject"), - content = email_template.get("response"), + content = frappe.render_template(email_template.get("response"),context), sender = sender, recipients = recipient, communication_medium = "Email",