Email template: how to fetch record's fields value and display it on email

I want to send mail with data of record.

Current code: HTML File.
body: Dear {record.raised_by}

In output: instead of fetching value from record and display it, it display as it is in email.

Can someone help me - how to fetch record’s fields value and display it on email while sending an email ?

You can use the method get_email from trytond.report. It returns an Python email message based on a report template in HTML.
You can see an example in account_dunning_email module.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.