Odoo Mindscape. Understand Odoo faster. Explore modules, fields, dependencies and version differences in one place instead of digging through the source code.

Module: Agreements Legal

Entity: agreement.section

Compute Method: _compute_dynamic_content

Inputs Method Outputs
MailTemplates = self.env["mail.template"]
for section in self:
            lang = (
                section.agreement_id and section.agreement_id.partner_id.lang or "en_US"
            )
            content = MailTemplates.with_context(lang=lang)._render_template(
                section.content, "agreement.section", [section.id]
            )[section.id]
            section.dynamic_content = content

Back to entity