From 0ce94ac23aa8db449ca1726f94a1cdf8042a4035 Mon Sep 17 00:00:00 2001 From: "Rifakat Haradwala (Open ERP)" Date: Wed, 20 Apr 2011 18:16:10 +0530 Subject: [PATCH] [FIX]: email_template: indentation bzr revid: rha@tinyerp.com-20110420124610-jpp6yc4b6qoxu8tf --- addons/email_template/email_template.py | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/addons/email_template/email_template.py b/addons/email_template/email_template.py index d8bc8711c79..192a42314a8 100644 --- a/addons/email_template/email_template.py +++ b/addons/email_template/email_template.py @@ -395,17 +395,17 @@ class email_template(osv.osv): data = {} data['model'] = template.model - # Ensure report is rendered using template's language - ctx = context.copy() - if template.lang: - ctx['lang'] = self.get_template_value(cr, uid, template.lang, template.model, record_id, context) - service = netsvc.LocalService(reportname) - (result, format) = service.create(cr, uid, [record_id], data, ctx) - result = base64.b64encode(result) - if not report_name: - report_name = reportname - report_name = report_name + "." + format - attachment[report_name] = result + # Ensure report is rendered using template's language + ctx = context.copy() + if template.lang: + ctx['lang'] = self.get_template_value(cr, uid, template.lang, template.model, record_id, context) + service = netsvc.LocalService(reportname) + (result, format) = service.create(cr, uid, [record_id], data, ctx) + result = base64.b64encode(result) + if not report_name: + report_name = reportname + report_name = report_name + "." + format + attachment[report_name] = result # Add document attachments for attach in template.attachment_ids: