We also have to update code calling directly the rendering itself. Indeed some code bits does some rendering directly on jinja-enabled input and not through templates. Those calls have to be updated accordingly. LINKS Task ID 1963529 Community PR odoo/odoo#32397
22 lines
572 B
Python
22 lines
572 B
Python
# -*- coding: utf-8 -*-
|
|
# Part of Odoo. See LICENSE file for full copyright and licensing details.
|
|
|
|
# Updating mako environement in order to be able to use slug
|
|
try:
|
|
from odoo.addons.mail.models.mail_render_mixin import jinja_template_env, jinja_safe_template_env
|
|
from odoo.addons.http_routing.models.ir_http import slug
|
|
|
|
jinja_template_env.globals.update({
|
|
'slug': slug,
|
|
})
|
|
|
|
jinja_safe_template_env.globals.update({
|
|
'slug': slug,
|
|
})
|
|
except ImportError:
|
|
pass
|
|
|
|
from . import controllers
|
|
from . import models
|
|
from . import wizard
|