Skip to content

Commit

Permalink
[MIG] mail_template_multi_company: Migration to 18.0
Browse files Browse the repository at this point in the history
  • Loading branch information
HeliconiaSolutions committed Dec 23, 2024
1 parent ba0a8c3 commit d5bd8f3
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 3 deletions.
1 change: 1 addition & 0 deletions mail_template_multi_company/README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@ Contributors
- Andrea Stirpe <a.stirpe@onestein.nl>
- Alberto Nieto de Pablos <alberto.nieto@braintec.com>
(https://braintec.com)
- `Heliconia Solutions Pvt. Ltd. <https://www.heliconia.io>`__

Maintainers
-----------
Expand Down
4 changes: 2 additions & 2 deletions mail_template_multi_company/__init__.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
from . import models


def post_init_hook(cr, registry):
def post_init_hook(env):
"""We should not set the company by default on all existing mail templates
when installing this module. Because many standard template need not be
specialized by company.
OTOH, when this module is installed it makes sense that new templates
being created by users have a company set by default."""
cr.execute("UPDATE mail_template SET company_id=null")
env.cr.execute("UPDATE mail_template SET company_id=null")
2 changes: 1 addition & 1 deletion mail_template_multi_company/__manifest__.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

{
"name": "Mail Template Multi Company",
"version": "16.0.1.0.0",
"version": "18.0.1.0.0",
"license": "AGPL-3",
"author": "ACSONE SA/NV," "Odoo Community Association (OCA)",
"website": "https://github.com/OCA/multi-company",
Expand Down
1 change: 1 addition & 0 deletions mail_template_multi_company/readme/CONTRIBUTORS.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,4 @@
- Andrea Stirpe \<<a.stirpe@onestein.nl>\>
- Alberto Nieto de Pablos \<<alberto.nieto@braintec.com>\>
(<https://braintec.com>)
- [Heliconia Solutions Pvt. Ltd.](https://www.heliconia.io)
1 change: 1 addition & 0 deletions mail_template_multi_company/static/description/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -428,6 +428,7 @@ <h2><a class="toc-backref" href="#toc-entry-6">Contributors</a></h2>
<li>Andrea Stirpe &lt;<a class="reference external" href="mailto:a.stirpe&#64;onestein.nl">a.stirpe&#64;onestein.nl</a>&gt;</li>
<li>Alberto Nieto de Pablos &lt;<a class="reference external" href="mailto:alberto.nieto&#64;braintec.com">alberto.nieto&#64;braintec.com</a>&gt;
(<a class="reference external" href="https://braintec.com">https://braintec.com</a>)</li>
<li><a class="reference external" href="https://www.heliconia.io">Heliconia Solutions Pvt. Ltd.</a></li>
</ul>
</div>
<div class="section" id="maintainers">
Expand Down

0 comments on commit d5bd8f3

Please sign in to comment.