Community mailing list archives

community@mail.odoo.com

Re: Error rendering email template jinja2 or mako is used ?

by
komsas
- 08/06/2014 16:27:36

If still crying you could grab this addon https://bitbucket.org/hacbee/email_template_i18n, is not perfect, but works.

On Aug 6, 2014 6:17 AM, "Ovnicraft" <ovnicraft@gmail.com> wrote:



On Tue, Aug 5, 2014 at 9:53 PM, Mario Arias <the.clone.master@gmail.com> wrote:
Hi Cristian,

When using email templates, it is easier to compute your values before rendering the template, and then passing the results in the context.
Inside the template, you reference them using ctx...

Yes, i am using ctx to solve all, thanks for your hint !, ( after all still crying by formatLang lolol )

Regards !

You can check out account_analytic_analysis_cron.xml for a sample...

Regards,
-Mario


On Tue, Aug 5, 2014 at 8:24 PM, Ovnicraft <ovnicraft@gmail.com> wrote:



On Fri, Aug 1, 2014 at 1:18 PM, komsas@gmail.com <komsas@gmail.com> wrote:

Hi,

Check the email_template addon, there is comment about jinja2 and its sanbox.


BTW its hard to cant call formatLang() for date and float type fields.

Regards,

Paulius

Hi to all, i am working on this in 7.0 so i load my template, its so simple

<p>${', '.join([e.name for e in object.exams]) }<p>

AFAIK mako is used to render mails why is jinja2 in my traceback ?

Any hints around ?

Regards,

--
 
Cristian Salamea on about.me
 
Cristian Salamea
 

_______________________________________________

_______________________________________________
Mailing-List: https://www.odoo.com/groups/community-59
Post to: mailto:community@mail.odoo.com
Unsubscribe: https://www.odoo.com/groups?unsubscribe




--
 
Cristian Salamea on about.me
 
Cristian Salamea
 

_______________________________________________


_______________________________________________
Mailing-List: https://www.odoo.com/groups/community-59
Post to: mailto:community@mail.odoo.com
Unsubscribe: https://www.odoo.com/groups?unsubscribe




--
 
Cristian Salamea on about.me
 
Cristian Salamea
 

_______________________________________________
Mailing-List: https://www.odoo.com/groups/community-59
Post to: mailto:community@mail.odoo.com
Unsubscribe: https://www.odoo.com/groups?unsubscribe