8a026e26c6ae25e3fdb5369a7fa3343d70fab782
Purpose of this commit is to allow to give additional values when rendering notification emails and to make some parameters explicit. This commit updates the _notify API. It allow to propagate a dictionary containing values given to the rendering of the notification template. This allow to have more complex templates and/or to control the rendering depending on some parameters. Indeed currently only some fixed values and values coming form the message to notify are given to the rendering context. First use will be soon when pushing notification emails not necessarily linked to documents. In this process some values will be given by the caller and not only by the message context anymore. This commit also moves some context key used to control the notification process directly in values given to the _notify method. It allows to make those parameters explicit and rely less on context. The _notify method now takes a values dictionary that may contain * add_sign: add user signature to notification email, default is True. It replaces the ``mail_notify_user_signature`` context key; * mail_auto_delete: auto delete send emails, default is True. It replaces the ``mail_auto_delete`` context key; * other values are given to the context used to render the notification template, allowing customization. It allows to remove some context switch notably in the composer. A values dictionary is computed and given to message_post and then propagated to the notification mechanism.
…
…
…
…
…
…
…
Odoo
Odoo is a suite of web based open source business apps.
The main Odoo Apps include an Open Source CRM, Website Builder, eCommerce, Warehouse Management, Project Management, Billing & Accounting, Point of Sale, Human Resources, Marketing, Manufacturing, Purchase Management, ...
Odoo Apps can be used as stand-alone applications, but they also integrate seamlessly so you get a full-featured Open Source ERP when you install several Apps.
Getting started with Odoo
For a standard installation please follow the Setup instructions from the documentation.
Then follow the developer tutorials
Languages
Python
49.6%
JavaScript
47.8%
SCSS
2%
CSS
0.3%
HTML
0.2%